Sha256: 2972c5dd13d20fda51d6660875f3561cff1e9035d030336a045b42280d6492f5

Contents?: true

Size: 634 Bytes

Versions: 4

Compression:

Stored size: 634 Bytes

Contents

# frozen_string_literal: true

module I18n::Tasks
  module Command
    module Commands
      module Interpolations
        include Command::Collection

        cmd :check_consistent_interpolations,
            pos: '[locale ...]',
            desc: t('i18n_tasks.cmd.desc.check_consistent_interpolations'),
            args: %i[locales out_format]

        def check_consistent_interpolations(opt = {})
          forest = i18n.inconsistent_interpolations(opt.slice(:locales, :base_locale))
          print_forest forest, opt, :inconsistent_interpolations
          :exit_1 unless forest.empty?
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
i18n-tasks-0.9.29 lib/i18n/tasks/command/commands/interpolations.rb
i18n-tasks-0.9.28 lib/i18n/tasks/command/commands/interpolations.rb
i18n-tasks-0.9.27 lib/i18n/tasks/command/commands/interpolations.rb
i18n-tasks-0.9.26 lib/i18n/tasks/command/commands/interpolations.rb