git-story-workflow 1.6.2 → 1.7.0

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
  SHA256:
3
- metadata.gz: b81ff3a4b94ba6bed90472b28eccdad8d3df7e4af30dc3ffe772cbef4ab78cc0
4
- data.tar.gz: b2b7347b35bd6d1f1ac63389091b8c0fe80bfb744604ba9b379e5a896fd3b682
3
+ metadata.gz: 596a9130689707c63f88c05175e839d2fd6618452096191d9f943ab7b0cf5273
4
+ data.tar.gz: e2917683df0992dc786210a6d666aa287f615501ab2334916d6a49c828579ddf
5
5
  SHA512:
6
- metadata.gz: '05349a0f364e7531b7a22602f4dea569498130b09aa90ab42a749d20b37a29b19a4da542b08fc88b418867d55e352d84a4c2ca7e4435585e8fe679b28807f604'
7
- data.tar.gz: b4fe39f78898e26603998ee218223a6d8b76ea895c50c2dcfe6329947e7e13923ef03921bea9bc28e8cd5488c06475a76618a1a3931404777208df81c5a298c1
6
+ metadata.gz: 58477df77c6ab0ffcfda37cd1089dca528bb19b412f5e5359271d5b9956537c001f283e798881deedcae90f6ffd4254f76e37c95d7872e04caf3af9f1122b034
7
+ data.tar.gz: ce696203a7f9955074fa7829d5c2afd31adb884154c9eca38820bd9f91a38b5f97c6ba01c99523c1155316652503289f7bd7030ff4b3f442ddecdddab0823278
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.6.2
1
+ 1.7.0
@@ -1,9 +1,9 @@
1
1
  # -*- encoding: utf-8 -*-
2
- # stub: git-story-workflow 1.6.2 ruby lib
2
+ # stub: git-story-workflow 1.7.0 ruby lib
3
3
 
4
4
  Gem::Specification.new do |s|
5
5
  s.name = "git-story-workflow".freeze
6
- s.version = "1.6.2"
6
+ s.version = "1.7.0"
7
7
 
8
8
  s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
9
9
  s.require_paths = ["lib".freeze]
@@ -26,12 +26,8 @@ class CommitMesssageParser
26
26
  def parse(template)
27
27
  @message_data = template.readlines
28
28
  @message_data.each do |line|
29
- if /^\s*\[.*(?:#\d+|TODO|(?<done>DONE)).*\]/i =~ line
29
+ if /^\s*\[.*(?:#\d{7,}).*\]/i =~ line
30
30
  @story_number_found = true
31
- if @story_number_done = !!done
32
- @message_data.slice!(@line_index)
33
- next
34
- end
35
31
  end
36
32
  if line =~ /^\s*#/
37
33
  break
@@ -58,7 +54,7 @@ class CommitMesssageParser
58
54
  end
59
55
 
60
56
  story_numbers =
61
- `git branch --no-color`.sub!(/^\* .*?(?:_(\d+(?:_\d+)*))$/) {
57
+ `git branch --no-color`.sub!(/^\* .*?(?:_(\d{7,}(?:_\d{7,})*))$/) {
62
58
  break $1.split(/_/)
63
59
  } || []
64
60
  story_numbers.map!(&:chomp)
@@ -67,8 +63,9 @@ Tempfile.open('commit') do |output|
67
63
  message_parsed = CommitMesssageParser.new.parse(template)
68
64
  if message_parsed.story_number_found?
69
65
  output.puts message_parsed.total
70
- elsif complex_config.story.todo_nudging? && story_numbers.empty? && !message_parsed.story_number_done?
71
- output.puts message_parsed.data, "", "[TODO]", "", message_parsed.footer
66
+ elsif story_numbers.empty?
67
+ template.rewind
68
+ output.puts template.read
72
69
  else
73
70
  full_message = [ message_parsed.data, "", ]
74
71
  if prefix = complex_config.story.pivotal_reference_prefix?
@@ -1,6 +1,6 @@
1
1
  module Git::Story
2
2
  # Git::Story version
3
- VERSION = '1.6.2'
3
+ VERSION = '1.7.0'
4
4
  VERSION_ARRAY = VERSION.split('.').map(&:to_i) # :nodoc:
5
5
  VERSION_MAJOR = VERSION_ARRAY[0] # :nodoc:
6
6
  VERSION_MINOR = VERSION_ARRAY[1] # :nodoc:
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: git-story-workflow
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.2
4
+ version: 1.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Florian Frank