aptible-cli 0.5.11 → 0.5.12
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/aptible/cli/subcommands/db.rb +9 -0
- data/lib/aptible/cli/version.rb +1 -1
- data/spec/aptible/cli/subcommands/db_spec.rb +3 -0
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3b91df96ab6a1f0df93fa8c72e66c6a6a5099e71
|
4
|
+
data.tar.gz: b1eaf8c6e6d4977757d69056257ebb127bba4b62
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0c464c35948b299c8ea1dbdba6eb6aaa09ecdee76410b7e9ea80337fbbc9fc25c0b1cf5c53e400cd0aa810933b585230beb1bbdd9684531c1f15db3d09d248a7
|
7
|
+
data.tar.gz: a8b6e992a70e29e3fcb5ec9682d1527ab11b72f13f2b19732d4b90420adbe9db2a8e5b5b83f5e950adcdf10aaa6b330761f08d66d3821b69ca68325bad5df402
|
@@ -56,6 +56,15 @@ module Aptible
|
|
56
56
|
|
57
57
|
say 'Creating tunnel...', :green
|
58
58
|
say "Connect at #{local_url(database, local_port)}", :green
|
59
|
+
|
60
|
+
uri = URI(local_url(database, local_port))
|
61
|
+
db = uri.path.gsub(%r{^/}, '')
|
62
|
+
say 'Or, use the following arguments:', :green
|
63
|
+
say("* Host: #{uri.host}", :green)
|
64
|
+
say("* Port: #{uri.port}", :green)
|
65
|
+
say("* Username: #{uri.user}", :green) unless uri.user.empty?
|
66
|
+
say("* Password: #{uri.password}", :green)
|
67
|
+
say("* Database: #{db}", :green) unless db.empty?
|
59
68
|
establish_connection(database, local_port)
|
60
69
|
end
|
61
70
|
|
data/lib/aptible/cli/version.rb
CHANGED
@@ -33,6 +33,9 @@ describe Aptible::CLI::Agent do
|
|
33
33
|
local_url = 'postgresql://aptible:password@127.0.0.1:4242/db'
|
34
34
|
expect(subject).to receive(:say).with('Creating tunnel...', :green)
|
35
35
|
expect(subject).to receive(:say).with("Connect at #{local_url}", :green)
|
36
|
+
|
37
|
+
# db:tunnel should also explain each component of the URL:
|
38
|
+
expect(subject).to receive(:say).exactly(6).times
|
36
39
|
subject.send('db:tunnel', 'foobar')
|
37
40
|
end
|
38
41
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aptible-cli
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.12
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Frank Macreery
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-11-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aptible-api
|
@@ -210,7 +210,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
210
210
|
version: '0'
|
211
211
|
requirements: []
|
212
212
|
rubyforge_project:
|
213
|
-
rubygems_version: 2.
|
213
|
+
rubygems_version: 2.4.5
|
214
214
|
signing_key:
|
215
215
|
specification_version: 4
|
216
216
|
summary: Command-line interface for Aptible services
|