Class: FalkorLib::CLI::App
- Inherits:
-
Thor
- Object
- Thor
- FalkorLib::CLI::App
show all
- Includes:
- FalkorLib::Common, Thor::Actions, ZshCompletion::Command
- Defined in:
- lib/falkorlib/cli.rb
Overview
Instance Method Summary
collapse
-
#commands ⇒ Object
-
#config(_key = '') ⇒ Object
-
#gitcrypt(path = '.') ⇒ Object
-
#init(name = '.') ⇒ Object
method_option :latex, :aliases => ‘-l’, :type => :boolean, :desc => “Initiate a LaTeX project” #method_option :gem, :type => :boolean, :desc => “Initiate a Ruby gem project” method_option :rvm, :type => :boolean, :desc => “Initiate a RVM-based Ruby project” method_option :ruby, :default => ‘1.9.3’, :desc => “Ruby version to configure for RVM” method_option :pyenv, :type => :boolean, :desc => “Initiate a pyenv-based Python project” method_option :octopress, :aliases => [‘-o’, ‘–www’], :type => :boolean, :desc => “Initiate an Octopress web site” _.
-
#mkdocs(path = '.') ⇒ Object
-
#motd(path = '.') ⇒ Object
-
#vagrant(path = '.') ⇒ Object
-
#version ⇒ Object
ask, bold, command?, cyan, error, exec_or_exit, execute, execute_in_dir, green, info, init_from_template, init_rvm, list_items, load_config, nice_execute, normalized_path, not_implemented, really_continue?, red, run, select_from, select_multiple_from, show_diff_and_write, store_config, warning, write_from_erb_template, write_from_template
Instance Method Details
#commands ⇒ Object
47
48
49
|
# File 'lib/falkorlib/cli.rb', line 47
def commands
puts App.all_commands.keys.sort - [ "zsh-completions"]
end
|
#config(_key = '') ⇒ Object
62
63
64
65
66
67
|
# File 'lib/falkorlib/cli.rb', line 62
def config(_key = '')
info "Thor options:"
puts options.to_yaml
info "FalkorLib internal configuration:"
puts FalkorLib.config.to_yaml
end
|
#gitcrypt(path = '.') ⇒ Object
#init(name = '.') ⇒ Object
method_option :latex, :aliases => ‘-l’, :type => :boolean, :desc => “Initiate a LaTeX project” #method_option :gem, :type => :boolean, :desc => “Initiate a Ruby gem project” method_option :rvm, :type => :boolean, :desc => “Initiate a RVM-based Ruby project” method_option :ruby, :default => ‘1.9.3’, :desc => “Ruby version to configure for RVM” method_option :pyenv, :type => :boolean, :desc => “Initiate a pyenv-based Python project” method_option :octopress, :aliases => [‘-o’, ‘–www’], :type => :boolean, :desc => “Initiate an Octopress web site” _
117
118
119
120
121
|
# File 'lib/falkorlib/cli.rb', line 117
def init(name = '.')
FalkorLib::Bootstrap.repo(name, options)
end
|
#mkdocs(path = '.') ⇒ Object
132
133
134
|
# File 'lib/falkorlib/cli.rb', line 132
def mkdocs(path = '.')
FalkorLib::Bootstrap.mkdocs(path, options)
end
|
#motd(path = '.') ⇒ Object
155
156
157
|
# File 'lib/falkorlib/cli.rb', line 155
def motd(path = '.')
FalkorLib::Bootstrap.motd(path, options)
end
|
#vagrant(path = '.') ⇒ Object
#version ⇒ Object
174
175
176
|
# File 'lib/falkorlib/cli.rb', line 174
def version
say "Falkor[Lib] version " + FalkorLib::VERSION, :yellow end
|