Class: EacCli::OldConfigs::StorePasswordsEntryReader
- Inherits:
-
EntryReader
- Object
- EntryReader
- EacCli::OldConfigs::StorePasswordsEntryReader
- Defined in:
- lib/eac_cli/old_configs/store_passwords_entry_reader.rb
Constant Summary collapse
- ENTRY_KEY =
'core.store_passwords'
Instance Method Summary collapse
- #banner ⇒ Object
-
#initialize(console_configs) ⇒ StorePasswordsEntryReader
constructor
A new instance of StorePasswordsEntryReader.
Methods inherited from EntryReader
entry_key_to_envvar_name, #read, #read_from_console, #read_from_envvars, #read_from_storage
Constructor Details
#initialize(console_configs) ⇒ StorePasswordsEntryReader
Returns a new instance of StorePasswordsEntryReader.
10 11 12 13 14 15 |
# File 'lib/eac_cli/old_configs/store_passwords_entry_reader.rb', line 10 def initialize(console_configs) super(console_configs, ENTRY_KEY, before_input: -> { }, validator: ->(entry_value) { %w[yes no].include?(entry_value) } ) end |
Instance Method Details
#banner ⇒ Object
17 18 19 20 21 22 |
# File 'lib/eac_cli/old_configs/store_passwords_entry_reader.rb', line 17 def infom 'Do you wanna to store passwords?' infom 'Warning: the passwords will be store in clear text in ' \ "\"#{console_configs.configs.storage_path}\"" infom 'Enter "yes" or "no"' end |