Class: PolyglotFlutter::Command::Pull

Inherits:
Object
  • Object
show all
Includes:
Helper::General, Helper::Terminal
Defined in:
lib/flutter_polyglot_cli/commands/pull.rb

Constant Summary

Constants included from Helper::General

Helper::General::ESCAPE_KEYWORDS

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Helper::General

#clean_enum_name, #clean_variable_name, #config, #escape_keyword_if_needed, #escape_with_underscore_if_needed, #extract_translations, #generate_locales, #generate_localization_keys, #indent, #mandatory_language, #programming_language, #project_configs, #token, #use_old_naming

Methods included from Helper::Terminal

#prompt, #success

Class Method Details

.initObject



7
8
9
# File 'lib/flutter_polyglot_cli/commands/pull.rb', line 7

def self.init
  new.call
end

Instance Method Details

#callObject



11
12
13
14
15
# File 'lib/flutter_polyglot_cli/commands/pull.rb', line 11

def call
  prompt.say('Fetching translations...')
  generate_translations(project_configs, programming_language, mandatory_language)
  success('Translations successfully generated!')
end