serverspec-runner 0.2.3 → 0.2.4

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: deb6b6b88775846ef3f209bde2980e2941af4f86
4
- data.tar.gz: c31f9fa20adbc3e2ead705ef3f2ffb0c45f034ad
3
+ metadata.gz: 0d66cd054c5793dc44643d11b0d9468b4d432a36
4
+ data.tar.gz: f02858d27f072f9bfe645a70d1e4de3a61209703
5
5
  SHA512:
6
- metadata.gz: 4e774ddd841a66cc479f81b6f9c2973aa0dfe5e75c46a40cc5943ecabce0ec881fca0bd5a7064eb6e372846f9e05bfb07d081aaacb8e4703cc40f0fa0e547603
7
- data.tar.gz: 26a1ce6ae5f55017bff20eee4ed9c1fc2faf04cd7192a40148dfd362e3c4db941666aba7bce9beea06a5d96cf206e135bed204bf317c162b282fe43badd5fc65
6
+ metadata.gz: e4aaf801fcdc918b5c126e1c5e91480ea69fbfa676063178a84a755460d8678fef14bba19d0efda0bcd7e435c9abfac62d825310112e18d77b46d264218bd96a
7
+ data.tar.gz: 96479e8df165d0f9be88c9ea1a50c5390a137ed002f35701155ee027892ca163f18de6f31ab6bb053ff7453042437d5bb8abd698b981d7af7d1858bfb75dc3d2
@@ -7,6 +7,7 @@ require 'rake'
7
7
  require 'getoptlong'
8
8
 
9
9
  raketask = 'spec'
10
+ showtasks = false
10
11
 
11
12
  opts = GetoptLong.new(
12
13
  ["--scenario", "-s", GetoptLong::REQUIRED_ARGUMENT],
@@ -16,7 +17,8 @@ opts = GetoptLong.new(
16
17
  ["--tableformat", "-t", GetoptLong::REQUIRED_ARGUMENT],
17
18
  ["--help", "-h", GetoptLong::NO_ARGUMENT],
18
19
  ["--tmpdir", "-1", GetoptLong::REQUIRED_ARGUMENT],
19
- ["--tasks", "-T", GetoptLong::REQUIRED_ARGUMENT]
20
+ ["--raketask", "-2", GetoptLong::REQUIRED_ARGUMENT],
21
+ ["--tasks", "-T", GetoptLong::NO_ARGUMENT]
20
22
  )
21
23
 
22
24
  opts.each do |opt, arg|
@@ -33,8 +35,10 @@ opts.each do |opt, arg|
33
35
  ENV['tableformat'] = arg
34
36
  when '--tmpdir'
35
37
  ENV['tmpdir'] = arg
36
- when '--tasks'
38
+ when '--raketask'
37
39
  raketask += "::" + arg
40
+ when '--tasks'
41
+ showtasks = true
38
42
  else
39
43
  puts "Usage: serverspec-runner (options)"
40
44
  puts "-s, --scenario SCENARIO_FILE path to scenario yml file"
@@ -48,5 +52,17 @@ opts.each do |opt, arg|
48
52
  end
49
53
  end
50
54
 
55
+ Rake::TaskManager.record_task_metadata = showtasks
51
56
  load "#{File.dirname(__FILE__)}/../Rakefile"
57
+
58
+ if showtasks
59
+ mLen = (Rake.application.tasks.max_by { |t| t.name_with_args.size }).name_with_args.size
60
+ Rake.application.tasks.reject{|t| ['spec:all', 'spec:stdout'].include?(t.name_with_args)}.each do |t|
61
+ printf("%-#{mLen + 2}s # %s\n",
62
+ t.name_with_args,
63
+ t.comment)
64
+ end
65
+ exit(0)
66
+ end
67
+
52
68
  Rake::Task[raketask.to_sym].invoke
@@ -1,3 +1,3 @@
1
1
  module ServerspecRunner
2
- VERSION = "0.2.3"
2
+ VERSION = "0.2.4"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: serverspec-runner
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 0.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - hiracy
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-10-18 00:00:00.000000000 Z
11
+ date: 2014-10-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: serverspec