Class: Pullentity::Client::CLI
- Inherits:
-
Thor
- Object
- Thor
- Pullentity::Client::CLI
show all
- Includes:
- Utils, Thor::Actions
- Defined in:
- lib/pullentity-client/cli.rb
Constant Summary
collapse
- STATUS_TYPES =
{:success => 0,
:general_error => 1,
:not_supported => 3,
:not_found => 4,
:incorrect_usage => 64,
}
Instance Method Summary
collapse
Methods included from Utils
#base_location, #create_directories, #create_new_file, #create_with_template, #error, #log, #remove_directories, #remove_files, source_root, #templates, #touch, #underscore
Instance Method Details
#build(type = "", ver = "5.1") ⇒ Object
method_option :attributes, :type => :hash, :default => {}, :required => true method_options :type => “all” method_options :ver => “5.1”
47
48
49
50
|
# File 'lib/pullentity-client/cli.rb', line 47
def build(type="", ver="5.1")
puts "echo ::== pullentity-client BUILD =="
::Pullentity::Client::Builder::Middleman.build
end
|
#info ⇒ Object
27
28
29
|
# File 'lib/pullentity-client/cli.rb', line 27
def info
say "Version #{::Pullentity::Client::VERSION}"
end
|
#login(email) ⇒ Object
55
56
57
|
# File 'lib/pullentity-client/cli.rb', line 55
def login(email)
::Pullentity::Client::Generate::Auth.start(['set_login', email])
end
|
#server ⇒ Object
33
34
35
36
|
# File 'lib/pullentity-client/cli.rb', line 33
def server
system "echo == :::pullentity-client STARTING::: =="
system "bundle exec middleman server"
end
|
#setup(email) ⇒ Object
62
63
64
65
66
|
# File 'lib/pullentity-client/cli.rb', line 62
def setup(email)
::Pullentity::Client::Generate::Auth.start(['set_login', email])
::Pullentity::Client::Generate::Auth.start(['select_site'])
::Pullentity::Client::Generate::Theme.start(['import_data'])
end
|