class FalkorLib::CLI::New

Thor class for all bootstrapping / initialization

Public Class Methods

banner(task, _namespace = true, subcommand = false) click to toggle source

Public Instance Methods

article(path = Dir.pwd) click to toggle source

_

# File lib/falkorlib/cli/new.rb, line 86
def article(path = Dir.pwd)
  (help(__method__) and exit 0) if options[:help]
  FalkorLib::Bootstrap.latex(path, :article, options)
end
commands() click to toggle source
# File lib/falkorlib/cli/new.rb, line 27
def commands
  puts New.all_commands.keys.sort - [ 'commands' ]
end
letter(path = Dir.pwd) click to toggle source

_

# File lib/falkorlib/cli/new.rb, line 98
def letter(path = Dir.pwd)
  (help(__method__) and exit 0) if options[:help]
  FalkorLib::Bootstrap.latex(path, :letter, options)
end
license(path = Dir.pwd) click to toggle source
# File lib/falkorlib/cli/new.rb, line 108
def license(path = Dir.pwd)
  (help(__method__) and exit 0) if options[:help]
  license = options[:license] ?  options[:license] : FalkorLib::Bootstrap.select_licence('none')
  FalkorLib::Bootstrap.license(path, license, '', options)
end
make(dir = Dir.pwd) click to toggle source
# File lib/falkorlib/cli/new.rb, line 129
def make(dir = Dir.pwd)
  (help(__method__) and exit 0) if options[:help]
  if options[:repo]
    FalkorLib::Bootstrap.makefile(dir)
  elsif (options[:latex] or options[:gnuplot] or options[:generic] or options[:images] or options[:src])
    FalkorLib::Bootstrap::Link.makefile(dir, options)
  else
    FalkorLib::Common.error 'Kindly precize the type of Makefile you which to create'
  end
end
pyenv(path = '.') click to toggle source

__

# File lib/falkorlib/cli/new.rb, line 169
def pyenv(path = '.')
  (help(__method__) and exit 0) if options[:help]
  FalkorLib::Bootstrap.pyenv(path, options)
end
readme(path = '.') click to toggle source
# File lib/falkorlib/cli/new.rb, line 245
def readme(path = '.')
  (help(__method__) and exit 0) if options[:help]  # pas boooooo
  FalkorLib::Bootstrap.readme(path, options)
end
repo(name = '.') click to toggle source

method_option :octopress, :aliases => [‘-o’, ‘–www’], :type => :boolean, :desc => “Initiate an Octopress web site” _

# File lib/falkorlib/cli/new.rb, line 68
def repo(name = '.')
  # TODO: find a generic way to handle help in subcommands
  # -- see https://github.com/erikhuda/thor/issues/532
  (help(__method__) and exit 0) if options[:help]
  options[:rvm] = true if options[:rake] || options[:gem]
  # _newrepo(name, options)
  FalkorLib::Bootstrap.repo(name, options)
end
rvm(path = '.') click to toggle source

__

# File lib/falkorlib/cli/new.rb, line 214
def rvm(path = '.')
  (help(__method__) and exit 0) if options[:help]
  FalkorLib::Bootstrap.rvm(path, options)
end
slides(path = Dir.pwd) click to toggle source

_

# File lib/falkorlib/cli/new.rb, line 181
def slides(path = Dir.pwd)
  (help(__method__) and exit 0) if options[:help]
  FalkorLib::Bootstrap.latex(path, :beamer, options)
end
trash(path = Dir.pwd) click to toggle source

__

# File lib/falkorlib/cli/new.rb, line 189
def trash(path = Dir.pwd)
  (help(__method__) and exit 0) if options[:help]
  FalkorLib::Bootstrap.trash(path)
end
versionfile(path = '.') click to toggle source

_

# File lib/falkorlib/cli/new.rb, line 228
def versionfile(path = '.')
  FalkorLib::Bootstrap.versionfile(path, options)
end