bin/connfu-client in connfu-client-0.1.1 vs bin/connfu-client in connfu-client-0.1.2

- old
+ new

@@ -26,10 +26,14 @@ \n EOS arg_name "project_name" command :scaffold do |c| + c.desc 'Application token' + c.default_value nil + c.flag :t + c.desc 'Channels the application should listen to' c.default_value nil c.flag :c c.desc 'Main file that will contain the application logic' @@ -46,19 +50,24 @@ c.switches.each do |s| usage << "\n -#{s[0]}: #{s[1].description}" end c.flags.each do |f| - usage << "\n -#{f[0]}: #{f[1].description}. Default value: #{f[1].default_value}" + usage << "\n -#{f[0]}: #{f[1].description}." + if f[1].default_value.nil? + usage << " (Optional parameter)" + else + usage << " Default value: #{f[1].default_value}" + end end usage << "\n\n" puts usage raise "" end puts " #{green("create")} #{args[0]}" - Connfu::Cli::Generator.run(args[0], options[:c], options[:f]) + Connfu::Cli::Generator.run(args[0], options[:c], options[:f], options[:t]) puts " #{green("create")} #{options[:f]}" puts " #{green("Application created!!")}" puts "\n" \ No newline at end of file