appli 0.0.5 → 0.0.6
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/appli/command.rb +2 -2
- data/lib/appli.rb +1 -1
- data/lib/commands/apps.rb +1 -1
- data/lib/commands/gems.rb +3 -2
- metadata +2 -2
data/lib/appli/command.rb
CHANGED
@@ -97,8 +97,8 @@ module Appli
|
|
97
97
|
api_request("http://#{domain}/#{path}", git_config_variable(:username), git_config_variable(:apikey), data)
|
98
98
|
end
|
99
99
|
|
100
|
-
def
|
101
|
-
api("applications/#{
|
100
|
+
def api_on_app(path, data = nil)
|
101
|
+
api("applications/#{@options[:application]}/#{path}", data)
|
102
102
|
end
|
103
103
|
|
104
104
|
def domain
|
data/lib/appli.rb
CHANGED
data/lib/commands/apps.rb
CHANGED
@@ -29,7 +29,7 @@ end
|
|
29
29
|
|
30
30
|
desc "Create a new application with the provided identifier"
|
31
31
|
usage "appli create {identifier}"
|
32
|
-
command "create", :global => true do |identifier|
|
32
|
+
command "create", :global => true, :required_args => 1 do |identifier|
|
33
33
|
puts "Creating new application with identifier '#{identifier}'. Please wait - this may take a few minutes."
|
34
34
|
result = api('applications', {:application => {:identifier => identifier, :name => identifier}}.to_json)
|
35
35
|
if errors
|
data/lib/commands/gems.rb
CHANGED
@@ -30,7 +30,7 @@ command "gems:import" do |file|
|
|
30
30
|
for g in gem_details.gems[0,4]
|
31
31
|
puts "Installing #{g[:name]} (#{g[:version] || 'latest'})"
|
32
32
|
data = {:ruby_gem => {:name => g[:name], :version => g[:version]}}.to_json
|
33
|
-
if
|
33
|
+
if api_on_app "ruby_gems", data
|
34
34
|
puts "=> Installed successfully"
|
35
35
|
else
|
36
36
|
puts "=> Installation failed"
|
@@ -43,9 +43,10 @@ usage "appli gems:install [gem name] [version]"
|
|
43
43
|
command "gems:install" do |name, version|
|
44
44
|
puts "Installing #{name} (#{version || 'latest'})"
|
45
45
|
data = {:ruby_gem => {:name => name, :version => version || ''}}.to_json
|
46
|
-
if a =
|
46
|
+
if a = api_on_app("ruby_gems", data)
|
47
47
|
puts "=> Installed"
|
48
48
|
else
|
49
|
+
puts errors.inspect
|
49
50
|
puts "=> Install failed"
|
50
51
|
end
|
51
52
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: appli
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Adam Cooke
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2010-02-
|
12
|
+
date: 2010-02-16 00:00:00 +00:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|