git_tools 0.3.2 → 0.3.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Rakefile +1 -0
- data/VERSION +1 -1
- data/git_tools.gemspec +1 -1
- data/lib/git_tools/hooks/prepare-commit-msg/01_capture_issue_tracker_number_from_branch_name.rb +4 -2
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3d30825406fc8a411689aa5cda1e57ef7ffed29b
|
4
|
+
data.tar.gz: 1b557251ae763367f7fe60aeab01c8d842afbd03
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 311ab97eae9528e7ec46782950bbe1c7c00ba608aa2884d5ac3c6cb2d2295013af7c79c038fdf4516cf6e54091bcd9bce5ceee65df223877bed65eca6fa67903
|
7
|
+
data.tar.gz: bfd8214bc882ead2b2ea1f2b6ddf7efeedd01b365a6a7a730a42bf50032e29153b3e9c537d62c3709baa269757cd14beaf950c02eb6eca5e4746612fcd7d6a2d
|
data/Rakefile
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.3.
|
1
|
+
0.3.3
|
data/git_tools.gemspec
CHANGED
@@ -13,7 +13,7 @@ Gem::Specification.new do |s|
|
|
13
13
|
|
14
14
|
s.rubyforge_project = "git_tools"
|
15
15
|
|
16
|
-
s.add_runtime_dependency("docopt")
|
16
|
+
s.add_runtime_dependency("docopt", '~> 0')
|
17
17
|
s.files = `git ls-files`.split("\n")
|
18
18
|
s.test_files = `git ls-files -- {test,spec}/*`.split("\n")
|
19
19
|
s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
|
data/lib/git_tools/hooks/prepare-commit-msg/01_capture_issue_tracker_number_from_branch_name.rb
CHANGED
@@ -13,7 +13,9 @@ contents = File.read(message_file)
|
|
13
13
|
|
14
14
|
has_merge_message = contents.match(/^Merge branch/m) # Commit with resolved merge conflicts don't have a commit source.
|
15
15
|
exit if has_merge_message
|
16
|
-
|
16
|
+
|
17
|
+
branch_name = contents.match(/^# On branch(.+)$/).captures.first.strip
|
18
|
+
ticket_no_from_branch_name = branch_name.scan(/[0-9]+/)
|
17
19
|
|
18
20
|
if ticket_no_from_branch_name.empty?
|
19
21
|
references = nil
|
@@ -24,7 +26,7 @@ if ticket_no_from_branch_name.empty?
|
|
24
26
|
MESSAGE
|
25
27
|
else
|
26
28
|
references = ticket_no_from_branch_name.join(', #')
|
27
|
-
default_line = "Issue
|
29
|
+
default_line = "Issue references: ##{references}"
|
28
30
|
end
|
29
31
|
|
30
32
|
if File.exists?(template_file)
|
metadata
CHANGED
@@ -1,27 +1,27 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: git_tools
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Birkir A. Barkarson
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-06-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: docopt
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
17
|
+
- - ~>
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '0'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- -
|
24
|
+
- - ~>
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
27
|
description: Git tools for installing hooks, cleaning up branches and more.
|
@@ -68,7 +68,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
68
68
|
version: '0'
|
69
69
|
requirements: []
|
70
70
|
rubyforge_project: git_tools
|
71
|
-
rubygems_version: 2.
|
71
|
+
rubygems_version: 2.2.2
|
72
72
|
signing_key:
|
73
73
|
specification_version: 4
|
74
74
|
summary: Collection of various handy git commands and tasks.
|