bushido 0.0.2 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/bin/bushido +17 -4
- data/lib/bushido/version.rb +1 -1
- data/lib/bushido.rb +4 -4
- metadata +2 -2
data/bin/bushido
CHANGED
@@ -3,8 +3,21 @@ require 'bushido'
|
|
3
3
|
|
4
4
|
options = {}
|
5
5
|
|
6
|
-
commands = [:create, :
|
7
|
-
|
6
|
+
commands = [:reauth, :claim, :list, :create, :show, :start, :stop, :restart, :update, :open]
|
7
|
+
|
8
|
+
help_docs = {
|
9
|
+
:reauth => "bushido reauth - Reauthorize this machine to work under your Bushido account",
|
10
|
+
:claim => "bushido claim [NAME] - Claim a running Bushido app as your own",
|
11
|
+
:list => "bushido list - List all of your deployed Bushido apps",
|
12
|
+
:create => "bushido create [URL] - Deploy a Bushido app from a git repository in URL",
|
13
|
+
:show => "bushido show [NAME] - Provide a detailed view of the Bushido app",
|
14
|
+
:start => "bushido start [NAME] - Turns the app on if it's been shut down for any reason",
|
15
|
+
:stop => "bushido stop [NAME] - Turns the app off to prevent any access",
|
16
|
+
:restart => "bushido restart [NAME] - Performace a stop and start in succession" ,
|
17
|
+
:update => "bushido update [NAME] - Will stop the running bushido app, pull from the url originally supplied to the app, update in place, and start back up",
|
18
|
+
:open => "bushido open [NAME] - Open browser window to the running Bushido app",
|
19
|
+
:create => "bushido create [NAME] - creates a new app"
|
20
|
+
}
|
8
21
|
|
9
22
|
OptionParser.new do |opts|
|
10
23
|
opts.banner = "Usage: bushido <command>"
|
@@ -16,7 +29,7 @@ OptionParser.new do |opts|
|
|
16
29
|
opts.on("-h", "--help [command]", commands, "Help (this screen)") do |h|
|
17
30
|
if h.nil?
|
18
31
|
puts opts
|
19
|
-
puts "Supported commands:
|
32
|
+
puts "Supported commands: #{commands.join(', ')}"
|
20
33
|
exit
|
21
34
|
end
|
22
35
|
|
@@ -47,5 +60,5 @@ if command
|
|
47
60
|
end
|
48
61
|
else
|
49
62
|
puts "usage: bushido <command>\n\nSee bushido -h for more detailed instructions"
|
50
|
-
puts "Supported commands:
|
63
|
+
puts "Supported commands: #{commands.join(', ')}"
|
51
64
|
end
|
data/lib/bushido/version.rb
CHANGED
data/lib/bushido.rb
CHANGED
@@ -5,10 +5,10 @@ module Bushido
|
|
5
5
|
require 'json'
|
6
6
|
require 'highline/import'
|
7
7
|
|
8
|
-
require "
|
9
|
-
require "
|
10
|
-
require "
|
11
|
-
require "
|
8
|
+
require "bushido/user"
|
9
|
+
require "bushido/utils"
|
10
|
+
require "bushido/command"
|
11
|
+
require "bushido/app"
|
12
12
|
|
13
13
|
|
14
14
|
Temple = ENV["HOST"] || "http://nok.tea.sh/"
|