Module: Paramore::Cli

Defined in:
lib/paramore/cli.rb

Class Method Summary collapse

Class Method Details

.config!Object



4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# File 'lib/paramore/cli.rb', line 4

def config!
  config_file_path = 'config/initializers/paramore.rb'

  if File.exists?(config_file_path)
    puts "#{config_file_path} already exists, skipping"
    exit 0
  end

  File.write(config_file_path, <<~CONF)
    Paramore.configure do |config|
      # what method name to call types with
      # config.type_method_name = :[]
    end
  CONF

  puts "#{config_file_path} created"
end