Class: SecretsCli::Init
- Inherits:
-
Object
- Object
- SecretsCli::Init
- Includes:
- Helpers
- Defined in:
- lib/secrets_cli/init.rb
Instance Attribute Summary collapse
-
#options ⇒ Object
readonly
Returns the value of attribute options.
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(options) ⇒ Init
constructor
A new instance of Init.
Methods included from Helpers
#error, #error!, #pastel, #pretty_diff, #print_verbose, #prompt
Constructor Details
#initialize(options) ⇒ Init
Returns a new instance of Init.
7 8 9 |
# File 'lib/secrets_cli/init.rb', line 7 def initialize() @options = end |
Instance Attribute Details
#options ⇒ Object (readonly)
Returns the value of attribute options.
5 6 7 |
# File 'lib/secrets_cli/init.rb', line 5 def @options end |
Instance Method Details
#call ⇒ Object
11 12 13 14 15 |
# File 'lib/secrets_cli/init.rb', line 11 def call SecretsCli::Configuration.write(config) prompt.ok "Written in #{SECRETS_CONFIG_FILE}:" prompt.ok File.read(SECRETS_CONFIG_FILE) end |