# i18n-tasks finds and manages missing and unused translations: https://github.com/glebm/i18n-tasks # The "main" locale. base_locale: en ## All available locales are inferred from the data by default. Alternatively, specify them explicitly: locales: [en, es] ## Reporting locale, default: en. Available: en, ru. # internal_locale: en # Read and write translations. data: ## Translations are read from the file system. Supported format: YAML, JSON. ## Provide a custom adapter: # adapter: I18n::Tasks::Data::FileSystem # Locale files or `File.find` patterns where translations are read from: read: ## Default: # - config/locales/%{locale}.yml ## More files: # - config/locales/**/*.%{locale}.yml ## Another gem (replace %#= with %=): # - "<%#= %x[bundle show vagrant].chomp %>/templates/locales/%{locale}.yml" - config/locales/%{locale}.yml - config/locales/admin.%{locale}.yml - config/locales/moderation.%{locale}.yml - config/locales/valuation.%{locale}.yml - config/locales/management.%{locale}.yml - config/locales/verification.%{locale}.yml - config/locales/mailers.%{locale}.yml - config/locales/pages.%{locale}.yml - config/locales/devise_views.%{locale}.yml - config/locales/responders.%{locale}.yml - config/locales/kaminari.%{locale}.yml # Locale files to write new keys to, based on a list of key pattern => file rules. Matched from top to bottom: # `i18n-tasks normalize -p` will force move the keys according to these rules write: ## For example, write devise and simple form keys to their respective files: # - ['{devise, simple_form}.*', 'config/locales/\1.%{locale}.yml'] ## Catch-all default: # - config/locales/%{locale}.yml ## Specify the router (see Readme for details). Valid values: conservative_router, pattern_router, or a custom class. # router: convervative_router yaml: write: # do not wrap lines at 80 characters line_width: -1 ## Pretty-print JSON: # json: # write: # indent: ' ' # space: ' ' # object_nl: "\n" # array_nl: "\n" # Find translate calls search: ## Paths or `File.find` patterns to search in: # paths: # - app/ ## Root directories for relative keys resolution. # relative_roots: # - app/controllers # - app/helpers # - app/mailers # - app/presenters # - app/views ## Files or `File.fnmatch` patterns to exclude from search. Some files are always excluded regardless of this setting: ## %w(*.jpg *.png *.gif *.svg *.ico *.eot *.otf *.ttf *.woff *.woff2 *.pdf *.css *.sass *.scss *.less *.yml *.json) exclude: - app/assets/images - app/assets/fonts ## Alternatively, the only files or `File.fnmatch patterns` to search in `paths`: ## If specified, this settings takes priority over `exclude`, but `exclude` still applies. # include: ["*.rb", "*.html.slim"] ## Default scanner finds t() and I18n.t() calls. # scanner: I18n::Tasks::Scanners::PatternWithScopeScanner ## Google Translate # translation: # # Get an API key and set billing info at https://code.google.com/apis/console to use Google Translate # api_key: "AbC-dEf5" ## Do not consider these keys missing: # ignore_missing: # - 'errors.messages.{accepted,blank,invalid,too_short,too_long}' # - '{devise,simple_form}.*' ignore_missing: - 'unauthorized.*' - 'activerecord.errors.models.proposal_notification.*' - 'activerecord.errors.models.direct_message.*' - 'errors.messages.blank' - 'errors.messages.taken' - 'devise.failure.invalid' - 'devise.registrations.destroyed' - 'devise.password_expired.*' ## Consider these keys used: ignore_unused: - 'activerecord.*' - 'activemodel.*' - 'unauthorized.*' - 'admin.officials.level_*' - 'admin.comments.index.filter*' - 'admin.banners.index.filters.*' - 'admin.debates.index.filter*' - 'admin.proposals.index.filter*' - 'admin.spending_proposals.index.filter*' - 'admin.organizations.index.filter*' - 'admin.users.index.filter*' - 'admin.activity.show.filter*' - 'admin.comments.index.hidden_*' - 'admin.settings.index.features.*' - 'moderation.comments.index.filter*' - 'moderation.comments.index.order*' - 'moderation.debates.index.filter*' - 'moderation.proposals.index.filter*' - 'moderation.proposals.index.order*' - 'moderation.debates.index.filter*' - 'moderation.debates.index.order*' - 'valuation.spending_proposals.index.filter*' - 'users.show.filters.*' - 'debates.index.select_order' - 'debates.index.orders.*' - 'debates.index.search_form.*' - 'proposals.index.select_order' - 'proposals.index.orders.*' - 'proposals.index.search_form.*' - 'spending_proposals.index.search_form.*' - 'notifications.index.comments_on*' - 'notifications.index.replies_to*' - 'notifications.index.proposal_notification*' - 'helpers.page_entries_info.*' # kaminari - 'views.pagination.*' # kaminari - 'shared.suggest.*' - 'invisible_captcha.*' # - '{devise,kaminari,will_paginate}.*' # - 'simple_form.{yes,no}' # - 'simple_form.{placeholders,hints,labels}.*' # - 'simple_form.{error_notification,required}.:' ## Exclude these keys from the `i18n-tasks eq-base' report: # ignore_eq_base: # all: # - common.ok # fr,es: # - common.brand ## Ignore these keys completely: # ignore: # - kaminari.*