diff --git a/src/kotatsu.cr b/src/kotatsu.cr index e5c8164..14bbe28 100644 --- a/src/kotatsu.cr +++ b/src/kotatsu.cr @@ -37,6 +37,16 @@ module Kotatsu exit end + parser.on "-mc", "--make-config", "Creates config file without running kotatsu" do + if File.exists?(CONFIG_FILE) == false + makeConfig(CONFIG_FILE, CONFIG_DIR) + exit + else + puts "Config already exists" + exit + end + end + parser.invalid_option do |flag| STDERR.puts "ERROR! Not a valid option: #{flag}" STDERR.puts "Use -h or --help for all available options"