Method: Neocities::CLI#initialize
- Defined in:
- lib/neocities/cli.rb
#initialize(argv) ⇒ CLI
Returns a new instance of CLI.
15 16 17 18 19 20 21 22 23 |
# File 'lib/neocities/cli.rb', line 15 def initialize(argv) @argv = argv.dup @pastel = Pastel.new eachline: "\n" @subcmd = @argv.first = @argv[1..@argv.length] @prompt = TTY::Prompt.new @api_key = ENV['NEOCITIES_API_KEY'] || nil @app_config_path = File.join self.class.app_config_path('neocities'), 'config' end |