captain_hoog 1.0.1 → 1.0.2
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.
- checksums.yaml +4 -4
- data/README.md +2 -0
- data/bin/githoog +7 -0
- data/changelog.md +10 -0
- data/features/support/steps/hooks_steps.rb +8 -0
- data/features/version.feature +8 -0
- data/lib/captain_hoog/plugin.rb +1 -1
- data/lib/captain_hoog/version.rb +1 -1
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d1878da510a740ed27d3cf1f5cce4e3a73e6d46f
|
4
|
+
data.tar.gz: d7599d7cd72adc61c6ccec8d4ffbcf037339868f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 48942a77df1cb93995ec9893e9e00ad5906aa667b32b107bb4b8a0ecdc8cd673f3baa515bbdec39ded1624325bfd6cb6145475b77d7c25efc4bdf38c90a7c33e
|
7
|
+
data.tar.gz: a885954742363a1d5f5226af584a52e9eb4dd90a51e3189ebbc103462ade5a21df5cb75dc17161f264140d6e1e70939f59c98b456547d80ac49b5ecff6c8f808
|
data/README.md
CHANGED
data/bin/githoog
CHANGED
@@ -19,6 +19,8 @@ class GitHookInstall < Thor
|
|
19
19
|
class_option :project_dir, type: :string, default: Dir.getwd
|
20
20
|
class_option :plugins_dir, type: :string, default: Dir.getwd
|
21
21
|
|
22
|
+
map %w[--version -v] => :__print_version
|
23
|
+
|
22
24
|
desc "install","Installs the hook into your Git repository"
|
23
25
|
def install(*args)
|
24
26
|
check_if_git_present
|
@@ -55,6 +57,11 @@ class GitHookInstall < Thor
|
|
55
57
|
puts "The #{options[:from]} hook is moved to #{options[:to]} hook.".green
|
56
58
|
end
|
57
59
|
end
|
60
|
+
|
61
|
+
desc "version, -v", "Prints out the version"
|
62
|
+
def __print_version
|
63
|
+
puts CaptainHoog::VERSION
|
64
|
+
end
|
58
65
|
|
59
66
|
private
|
60
67
|
|
data/changelog.md
CHANGED
@@ -42,6 +42,14 @@ Then(/^a "(.*?)" hook file did not exists$/) do |hook_type|
|
|
42
42
|
expect(File.exists?(hooks_path(hook_type))).to be false
|
43
43
|
end
|
44
44
|
|
45
|
+
Given(/^I type in "(.*?)"$/) do |arg1|
|
46
|
+
run_simple(arg1)
|
47
|
+
end
|
48
|
+
|
49
|
+
Then(/^I should see the current version$/) do
|
50
|
+
expect(all_stdout.split(/\n/).first).to match(/\d{1,}.\d{1,}.\d{1,}/)
|
51
|
+
end
|
52
|
+
|
45
53
|
When(/^I run the move script with "(.*?)" from flag and "(.*?)" to flag$/) do |from, to|
|
46
54
|
cmd = "ruby #{bin_path}/bin/githoog move --from #{from} --to #{to}"
|
47
55
|
run_simple(unescape(cmd), false)
|
@@ -0,0 +1,8 @@
|
|
1
|
+
Feature: Getting the gems version number printed to stdout
|
2
|
+
In order to get the version printed out to stdout
|
3
|
+
As developer
|
4
|
+
I want to type in githoog --version to know about the current version
|
5
|
+
|
6
|
+
Scenario: Getting the version printed to stdout
|
7
|
+
Given I type in "githoog --version"
|
8
|
+
Then I should see the current version
|
data/lib/captain_hoog/plugin.rb
CHANGED
data/lib/captain_hoog/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: captain_hoog
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Daniel Schmidt
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-05-
|
11
|
+
date: 2015-05-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: colorize
|
@@ -159,6 +159,7 @@ files:
|
|
159
159
|
- features/support/env.rb
|
160
160
|
- features/support/steps/hooks_steps.rb
|
161
161
|
- features/support/world.rb
|
162
|
+
- features/version.feature
|
162
163
|
- lib/captain_hoog.rb
|
163
164
|
- lib/captain_hoog/config/hook_types.yml
|
164
165
|
- lib/captain_hoog/core_ext.rb
|
@@ -231,6 +232,7 @@ test_files:
|
|
231
232
|
- features/support/env.rb
|
232
233
|
- features/support/steps/hooks_steps.rb
|
233
234
|
- features/support/world.rb
|
235
|
+
- features/version.feature
|
234
236
|
- spec/fixtures/code/helper.rb
|
235
237
|
- spec/fixtures/config/cucumber/hoogfile.yml
|
236
238
|
- spec/fixtures/config/spec/hoogfile.yml
|