awssh 0.2.2 → 0.2.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 64c9aaccc334ae6c8592e86c0addcfee0f0124c2
4
- data.tar.gz: 5a8315b70d09b1f9ecd0e4e56a325307180df20a
3
+ metadata.gz: fbcb9800f5e1861bdde7e4cab2a488ca3f881916
4
+ data.tar.gz: 88063803260ce7e0a79bd634e541eab5c5402348
5
5
  SHA512:
6
- metadata.gz: 288a4ff1f6f12dc8b5886bd2b1d39483038ae5f727f0039f9c9948f57683407aea32333178794cbab914434330bb7847fb43429942a7054e5f0495a0add509b3
7
- data.tar.gz: 4a56f8c974e775f88878fab42846619af4d5899e398ff65606f459e384d9a8f6dd1d9af846b97a68bbfd9861c47e1f1bacac1c81f43cfcfd8e2da821cd80469e
6
+ metadata.gz: a4a9c26c2d65c02c9aa8287f5394cc1941f7d9d6df8a9d9a3ced3aaf130ae2ac42a88be29110f72602a7997bb7e53f2c3c250ca232947fa52be18e401d826bc0
7
+ data.tar.gz: c0977a1e9491667d97ead7390eb3bb82b105f2361008054529b68ee4771b48dac80e64366d423f1a780679c87e0ae793494bef1bc79740dac6d6b58cc7ecbd49
@@ -8,6 +8,7 @@ module Awssh
8
8
  multi: false,
9
9
  test: false,
10
10
  list: false,
11
+ identity: nil,
11
12
  }
12
13
  @config = {
13
14
  multi: 'csshX',
@@ -41,7 +42,10 @@ module Awssh
41
42
  puts "awssh version: #{Awssh::Version::STRING}"
42
43
  exit 0
43
44
  end
44
- opts.on('-i', '--init', 'initialize config') do |i|
45
+ opts.on('-iIDENTITY', '--identity=IDENTITY', 'set ssh key') do |i|
46
+ @options[:identity] = i
47
+ end
48
+ opts.on('--init', 'initialize config') do |i|
45
49
  path = File.expand_path(@options[:config])
46
50
  puts "creating config file: #{path}"
47
51
  if File.exists?(path)
@@ -130,10 +134,11 @@ module Awssh
130
134
  end
131
135
 
132
136
  def command(hosts)
137
+ id = @options[:identity] ? "-i #{@options[:identity]}" : nil
133
138
  if @options[:multi]
134
- command = "#{@config.multi} #{hosts.map { |e| host(e) }.join(' ')}"
139
+ command = "#{@config.multi} #{id} #{hosts.map { |e| host(e) }.join(' ')}"
135
140
  else
136
- command = "#{@config.single} #{host(hosts.first)}"
141
+ command = "#{@config.single} #{id} #{host(hosts.first)}"
137
142
  end
138
143
  command
139
144
  end
@@ -2,7 +2,7 @@ module Awssh
2
2
  module Version
3
3
  MAJOR = 0
4
4
  MINOR = 2
5
- TINY = 2
5
+ TINY = 3
6
6
  TAG = nil
7
7
  LIST = [MAJOR, MINOR, TINY, TAG].compact
8
8
  STRING = LIST.join('.')
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: awssh
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Shawn Catanzarite
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-05-25 00:00:00.000000000 Z
11
+ date: 2015-06-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: fog