diff --git a/ftl/.gitignore b/ftl/.gitignore new file mode 100644 index 000000000..738260199 --- /dev/null +++ b/ftl/.gitignore @@ -0,0 +1,2 @@ +usage + diff --git a/ftl/remove-unused.sh b/ftl/remove-unused.sh index f4d932157..73ec9f926 100755 --- a/ftl/remove-unused.sh +++ b/ftl/remove-unused.sh @@ -1,5 +1,14 @@ #!/bin/bash - +# +# To use, run: +# +# - ./update-ankimobile-usage.sh +# - ./remove-unused.sh +# +# If you need to maintain compatibility with an older stable branch, you +# can use ./update-desktop-usage.sh in the older release, then copy the +# generated file into usage/ with a different name. +# # Caveats: # - Messages are considered in use if they are referenced in other messages, # even if those messages themselves are not in use and going to be deleted. diff --git a/ftl/update-ankimobile-usage.sh b/ftl/update-ankimobile-usage.sh index c14e56edc..e68620f04 100755 --- a/ftl/update-ankimobile-usage.sh +++ b/ftl/update-ankimobile-usage.sh @@ -7,7 +7,7 @@ set -e scriptRoot=$(realpath $(dirname $0)/..) -sourceRoot=$(realpath $scriptRoot/../mob/src) +sourceRoot=$(realpath $scriptRoot/../../mobile/ankimobile/src) bazel run //rslib/i18n_helpers:write_ftl_json $scriptRoot/ftl/usage/ankimobile.json \ $sourceRoot diff --git a/ftl/usage/.gitignore b/ftl/usage/.gitignore deleted file mode 100644 index f1be7f494..000000000 --- a/ftl/usage/.gitignore +++ /dev/null @@ -1 +0,0 @@ -desktop-head.json diff --git a/ftl/usage/ankimobile.json b/ftl/usage/ankimobile.json deleted file mode 100644 index fb4963acb..000000000 --- a/ftl/usage/ankimobile.json +++ /dev/null @@ -1,574 +0,0 @@ -[ - "about-anki-written-by", - "about-license-text", - "about-please-see", - "about-some-thirdparty-libraries", - "about-thanks-contributors", - "about-thanks-for-support", - "about-the-anki-homepage", - "actions-actions", - "actions-add", - "actions-add-new", - "actions-add-short", - "actions-added-to-frequent-actions", - "actions-all-actions", - "actions-already-in-frequent-actions", - "actions-an-error-occurred", - "actions-answer-again", - "actions-answer-again-short", - "actions-answer-easy", - "actions-answer-easy-short", - "actions-answer-good", - "actions-answer-good-short", - "actions-answer-hard", - "actions-answer-hard-short", - "actions-are-you-sure", - "actions-auto-advance", - "actions-auto-advance-short", - "actions-bottom-bar", - "actions-bottom-bar-short", - "actions-browse", - "actions-browse-short", - "actions-bury-card-short", - "actions-bury-note-short", - "actions-cancel", - "actions-card-info", - "actions-card-info-short", - "actions-card-template", - "actions-card-template-short", - "actions-close", - "actions-confirm-delete", - "actions-current-audio-minus5s", - "actions-current-audio-minus5s-short", - "actions-current-audio-plus5s", - "actions-current-audio-plus5s-short", - "actions-custom-study", - "actions-custom-study-cant-be-used-on", - "actions-custom-study-short", - "actions-deck-statistics", - "actions-deck-statistics-short", - "actions-decks", - "actions-decks-short", - "actions-delete", - "actions-delete-note-short", - "actions-discard-changes", - "actions-done", - "actions-downloading", - "actions-drag-here-to-remove", - "actions-draw", - "actions-edit-short", - "actions-empty-short", - "actions-export", - "actions-file-invalid-or-corrupt", - "actions-filter", - "actions-filter-short", - "actions-filtercram", - "actions-flag-blue", - "actions-flag-green", - "actions-flag-number", - "actions-flag-orange", - "actions-flag-pink", - "actions-flag-purple", - "actions-flag-red", - "actions-flag-turquoise", - "actions-frequent-actions", - "actions-import", - "actions-leave-without-saving", - "actions-long-press-on-an-item-to", - "actions-mark", - "actions-mark-and-bury", - "actions-mark-and-bury-short", - "actions-mark-and-suspend", - "actions-mark-and-suspend-short", - "actions-mark-short", - "actions-new-name", - "actions-night-mode-short", - "actions-no-current-card", - "actions-no-load-restore-backup", - "actions-not-valid-link", - "actions-nothing-to-redo", - "actions-nothing-to-undo", - "actions-off", - "actions-off-short", - "actions-options", - "actions-options-for", - "actions-pause-audio-short", - "actions-please-tap-the-in-the", - "actions-preview", - "actions-processing", - "actions-rebuild", - "actions-rebuild-short", - "actions-record-voice", - "actions-record-voice-menu", - "actions-record-voice-short", - "actions-redo-short", - "actions-rename", - "actions-rename-deck", - "actions-replay-audio", - "actions-replay-audio-short", - "actions-replay-voice-short", - "actions-reset-card", - "actions-reset-card-short", - "actions-revert", - "actions-review-undone", - "actions-save", - "actions-scratchpad", - "actions-scratchpad-short", - "actions-scratchpad-size", - "actions-scratchpad-size-short", - "actions-search", - "actions-select-deck", - "actions-select-note-type", - "actions-set-due-date", - "actions-set-due-date-short", - "actions-show-answer-short", - "actions-show-answeranswer-good", - "actions-show-answeranswer-good-short", - "actions-study-options", - "actions-study-options-short", - "actions-suspend-card", - "actions-suspend-card-short", - "actions-suspend-note-short", - "actions-tools", - "actions-tools-overlay", - "actions-tools-short", - "actions-top-bar", - "actions-top-bar-short", - "actions-unbury-deck", - "actions-unbury-deck-short", - "actions-undo", - "actions-undo-short", - "adding-added", - "adding-cloze-outside-cloze-field", - "adding-cloze-outside-cloze-notetype", - "adding-the-first-field-is-empty", - "adding-you-have-a-cloze-deletion-note", - "browsing-added-today", - "browsing-again-today", - "browsing-any-flag", - "browsing-append", - "browsing-append-negated", - "browsing-card-updated", - "browsing-cards-deleted", - "browsing-cards-updated", - "browsing-change-deck", - "browsing-change-flag", - "browsing-change-note-type", - "browsing-change-notetype", - "browsing-clear-flag", - "browsing-clear-unused-tags", - "browsing-column1", - "browsing-column2", - "browsing-confirm-reset", - "browsing-current-deck", - "browsing-dd-selected", - "browsing-delete-notes", - "browsing-due-dateorder", - "browsing-due-reviews", - "browsing-ease", - "browsing-filtered", - "browsing-find", - "browsing-find-and-replace", - "browsing-interval", - "browsing-learning-cards", - "browsing-no-cards-are-selected", - "browsing-no-flag", - "browsing-note-created", - "browsing-note-updated", - "browsing-note2", - "browsing-notes-updated", - "browsing-question", - "browsing-questionandanswer", - "browsing-removed-unused-tags-count", - "browsing-repetitions", - "browsing-replace-with", - "browsing-reschedule", - "browsing-reset-cards", - "browsing-row-deleted", - "browsing-searching", - "browsing-second-column19", - "browsing-second-column91", - "browsing-select-all", - "browsing-sort", - "browsing-sort-field", - "browsing-sort-order", - "browsing-studied-today", - "browsing-suspended", - "browsing-tag", - "browsing-toggle-suspend", - "browsing-whole-collection", - "card-stats-note-type", - "card-templates-flip", - "card-templates-night-mode", - "card-templates-template-styling", - "custom-study-any-tag", - "custom-study-available", - "custom-study-cant-extend-limits-no-extra", - "custom-study-cram-seen-cards-with-certain-tags", - "custom-study-custom-study-session", - "custom-study-days-to-look-ahead", - "custom-study-days-to-look-back", - "custom-study-exclude-cards-with-tag", - "custom-study-extra-new-cards", - "custom-study-extra-review-cards", - "custom-study-include-cards-with-tag", - "custom-study-increase-todays-new-card-limit", - "custom-study-increase-todays-review-card-limit", - "custom-study-learn-new-cards-with-certain-tags", - "custom-study-loading", - "custom-study-max-cards-to-gather", - "custom-study-no-tags", - "custom-study-no-tags-available", - "custom-study-ok", - "custom-study-preview-all-cards-with-certain-tags", - "custom-study-preview-new-cards", - "custom-study-review-ahead", - "custom-study-review-due-cards-with-certain-tags", - "custom-study-review-forgotten-cards", - "custom-study-search-matches", - "custom-study-select", - "custom-study-study-type", - "custom-study-the-selected-options-did-not-match", - "database-check-rebuilt", - "database-check-title", - "deck-config-title", - "deck-config-used-by-decks", - "deck-options-add-options-group", - "deck-options-answer-time-cap", - "deck-options-bury-related-new-cards", - "deck-options-bury-related-reviews", - "deck-options-defaults", - "deck-options-delete-options-full-sync", - "deck-options-display-in-order-added", - "deck-options-display-in-random-order", - "deck-options-full-sync-required", - "deck-options-group-name", - "deck-options-max-new-per-day", - "deck-options-max-reviews-per-day", - "deck-options-new-cards", - "deck-options-options-group", - "deck-options-replay-q-audio-in-answer", - "deck-options-reset-all-settings-to-defaults", - "deck-options-restore-defaults", - "deck-options-steps", - "decks-a-deck-must-be-provided", - "decks-a-deck-named-already-exists", - "decks-add-empty-deck", - "decks-addexport", - "decks-build", - "decks-card-limit", - "decks-custom-steps", - "decks-deck", - "decks-deck-label", - "decks-deck-name", - "decks-deck-options", - "decks-download-link", - "decks-enable-second-filter", - "decks-export-collection", - "decks-filter2", - "decks-import-from-itunes", - "decks-link-to-apkg-file-to-import", - "decks-return-by-delete", - "decks-shared-deck-list", - "decks-study", - "decks-sync", - "decks-synchronize", - "decks-the-provided-deck-does-not-exist", - "decks-will-be-returned", - "editing-add-media", - "editing-bold", - "editing-cant-edit-original-image-data", - "editing-card-unsuspended", - "editing-discard", - "editing-discard-changes-question", - "editing-fields", - "editing-from-camera", - "editing-from-file", - "editing-from-photos", - "editing-italic", - "editing-keep-editing", - "editing-next-cloze", - "editing-next-field", - "editing-note-type-prompt", - "editing-note-unsuspended", - "editing-same-cloze", - "editing-tags", - "editing-unable-to-obtain-image", - "editing-unable-to-read-file", - "editing-underline", - "editing-unexpected-file-extension", - "editing-unexpected-rich-text-format-please", - "editing-unexpected-status-code", - "editing-unsuspend-card", - "editing-unsuspend-note", - "empty-cards-delete-button", - "empty-cards-delete-empty-cards", - "empty-cards-delete-empty-notes", - "empty-cards-deleted-count", - "empty-cards-deleting", - "empty-cards-not-found", - "empty-cards-window-title", - "errors100-tags-max", - "exporting-collection-saved-to-itunes", - "exporting-export-to-itunes", - "exporting-export-to-share-sheet", - "exporting-exporting", - "exporting-include-media2", - "exporting-media-files-exported-d", - "findreplace-notes-updated", - "importing-delete-imported-file", - "importing-import-complete", - "importing-importing", - "importing-no-apkg-or-colpkg-files-were", - "importing-overwrite-via-import", - "importing-please-choose-a-file", - "importing-processed-media-files-d", - "importing-replace-collection", - "media-check-check-media-action", - "media-check-delete-unused", - "media-check-delete-unused-complete", - "media-check-empty-trash", - "media-check-files-remaining", - "media-check-restore-trash", - "media-check-trash-emptied", - "media-check-trash-restored", - "media-check-window-title", - "media-error-initializing-recorder", - "media-error-playing-audio-full", - "media-privacy-microphone", - "media-recording", - "notetypes-back-field", - "notetypes-cloze-name", - "notetypes-front-field", - "preferences-about", - "preferences-always-duck-and-ignore-mute", - "preferences-answer-keeps-zoom", - "preferences-answer-side", - "preferences-audio-buttons", - "preferences-auto-advance-answer-action", - "preferences-auto-advance-answer-seconds", - "preferences-auto-advance-auto-advance-to-start", - "preferences-auto-advance-do-nothing", - "preferences-auto-advance-question-seconds", - "preferences-auto-advance-show-reminder", - "preferences-auto-advance-wait-for-audio", - "preferences-backup-available-backups", - "preferences-backup-create-now", - "preferences-backup-maximum-backups", - "preferences-backup-minutes-between-backups", - "preferences-backup-revert-to-backup", - "preferences-backup-revert-to-backup-confirm", - "preferences-backup-reverted-to-backup", - "preferences-backups", - "preferences-bottom-bar-size", - "preferences-bottom-center", - "preferences-bottom-left", - "preferences-bottom-right", - "preferences-button-d", - "preferences-collection-day-starts", - "preferences-collection-learn-ahead-minutes", - "preferences-collection-mix", - "preferences-collection-new-first", - "preferences-collection-newreview-order", - "preferences-collection-reviews-first", - "preferences-double-tap-prevention", - "preferences-drawing-screen-ignores-fingers", - "preferences-editing", - "preferences-editing-convert-smart-quotes", - "preferences-editing-crop-camera-photos", - "preferences-editing-max-image-size", - "preferences-editing-resize-on-paste", - "preferences-feedback-ticks", - "preferences-fine", - "preferences-force-sync-confirm", - "preferences-full-sync", - "preferences-gamepad-button-mapping", - "preferences-gamepad-menu-button", - "preferences-gamepads", - "preferences-height", - "preferences-huge", - "preferences-ignore-fingers", - "preferences-interrupt-current-audio", - "preferences-large", - "preferences-left", - "preferences-left-shoulder", - "preferences-left-thumbstick-button", - "preferences-left-trigger", - "preferences-logged-in-as", - "preferences-long", - "preferences-mid-center", - "preferences-mid-left", - "preferences-mid-right", - "preferences-never-show-scratchpad", - "preferences-never-show-scratchpad-enabled", - "preferences-never-type-answer", - "preferences-next-times", - "preferences-normal", - "preferences-notifications", - "preferences-notifications-alert-time", - "preferences-notifications-alert-when-due", - "preferences-notifications-app-icon-shows-due-count", - "preferences-notifications-settings-app-enable-notifications", - "preferences-paste-clipboard-images-as-png", - "preferences-pen-size", - "preferences-preferences", - "preferences-question-side", - "preferences-remaining-count", - "preferences-right", - "preferences-right-shoulder", - "preferences-right-thumbstick-button", - "preferences-right-trigger", - "preferences-scheduling", - "preferences-scratchpad-below-buttons", - "preferences-scratchpad-transparency", - "preferences-scratchpad-transparency-full", - "preferences-scratchpad-transparency-medium", - "preferences-scratchpad-transparency-none", - "preferences-scratchpad-transparency-slight", - "preferences-shake-action", - "preferences-short", - "preferences-show-bottom-bar", - "preferences-show-grid", - "preferences-show-top-bar", - "preferences-small", - "preferences-swipe-down", - "preferences-swipe-left", - "preferences-swipe-right", - "preferences-swipe-up", - "preferences-swipes", - "preferences-swipes-must-begin-from-the-far", - "preferences-sync-sounds-images", - "preferences-syncing", - "preferences-tap-to-sync", - "preferences-taps", - "preferences-theme", - "preferences-theme-bar-style", - "preferences-theme-black", - "preferences-theme-dark", - "preferences-theme-dark-translucent", - "preferences-theme-force-off", - "preferences-theme-force-on", - "preferences-theme-light-translucent", - "preferences-theme-night-mode-desc", - "preferences-theme-night-mode-same-as-system", - "preferences-theme-slate", - "preferences-thick", - "preferences-tools-overlay-button", - "preferences-tools-overlay-position", - "preferences-top-center", - "preferences-top-left", - "preferences-top-right", - "preferences-undo-clears-all", - "preferences-when-answer-shown", - "preferences-when-question-shown", - "preferences-you-have-been-logged-out", - "profiles-a-profile-with-that-name-already", - "profiles-add-profile", - "profiles-creating-backup", - "profiles-finishing-backup", - "profiles-please-provide-some-text-avoiding-symbols", - "profiles-please-select-another-profile-first", - "profiles-profile-name", - "profiles-profiles", - "profiles-rename-profile", - "profiles-unable-to-open-safari-please", - "profiles-user1", - "profiles-welcome", - "scheduling-automatically-play-audio", - "scheduling-easy-bonus", - "scheduling-easy-interval", - "scheduling-end", - "scheduling-forgot-cards", - "scheduling-general", - "scheduling-graduating-interval", - "scheduling-interval-modifier", - "scheduling-lapses", - "scheduling-leech-action", - "scheduling-leech-threshold", - "scheduling-maximum-interval", - "scheduling-minimum-interval", - "scheduling-new-cards", - "scheduling-new-interval", - "scheduling-order", - "scheduling-review", - "scheduling-reviews", - "scheduling-set-due-date-done", - "scheduling-set-due-date-prompt", - "scheduling-set-due-date-prompt-hint", - "scheduling-starting-ease", - "scheduling-steps-in-minutes", - "scheduling-tag-only", - "scheduling-update-button", - "scheduling-update-done", - "scheduling-update-later-button", - "scheduling-update-more-info-button", - "scheduling-update-soon", - "statistics-answer-buttons-title", - "statistics-reviews", - "studying-again", - "studying-answer-time-elapsed", - "studying-auto-advance-starting", - "studying-auto-advance-stopped", - "studying-bury-card", - "studying-bury-note", - "studying-card-suspended", - "studying-card-was-a-leech", - "studying-cards-buried", - "studying-delete-note", - "studying-easy", - "studying-edit", - "studying-empty", - "studying-finish", - "studying-good", - "studying-hard", - "studying-have-ready-to-study", - "studying-note-suspended", - "studying-pause-audio", - "studying-please-run-empty-cards-on-the", - "studying-please-use-record-voice-first", - "studying-replay-card", - "studying-replay-voice", - "studying-show-answer", - "studying-suspend-note", - "studying-type-in-the-answer", - "sync-abort-button", - "sync-cancel-button", - "sync-checking", - "sync-confirm-empty-download", - "sync-conflict-explanation", - "sync-connecting", - "sync-download-from-ankiweb", - "sync-downloading-from-ankiweb", - "sync-email-address", - "sync-log-out-button", - "sync-login", - "sync-media-aborted", - "sync-media-complete", - "sync-media-disabled", - "sync-media-failed", - "sync-media-is-syncing", - "sync-media-log-button", - "sync-media-log-title", - "sync-media-missing-file", - "sync-media-show-progress", - "sync-media-starting", - "sync-must-wait-for-end", - "sync-password", - "sync-please-enter-your-ankiweb-details", - "sync-upload-to-ankiweb", - "sync-uploading-to-ankiweb", - "sync-wrong-pass", - "undo-action-redone", - "undo-action-undone", - "undo-redo", - "undo-redo-action", - "undo-undo", - "undo-undo-action", - "urlscheme-a-note-type-must-be-provided", - "urlscheme-a-note-with-the-same-first", - "urlscheme-a-profile-must-be-provided", - "urlscheme-added-note", - "urlscheme-invalid-profile-name", - "urlscheme-the-provided-note-type-does-not", - "urlscheme-unable-to-open-profile" -] \ No newline at end of file