git-story-workflow 0.7.1 → 0.8.0
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/VERSION +1 -1
- data/git-story-workflow.gemspec +3 -3
- data/lib/git/story/app.rb +21 -3
- data/lib/git/story/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6f6c3dc177ec79d537e3e345a353a263d81010564fc28ff8ed163c5a35b7d559
|
4
|
+
data.tar.gz: f9cf57b5600ce2c7d88645aca0e117ddee5b86ae6a8c8d9ed52c3863c579458b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 41e58403c7074b473e1beeb64e972a857474b79c7965108f2d285a7ebdfbfcedc35e04b682019ab387620cf4c94e17ad433d9f4fdb1bad588b3786fa589a1cc8
|
7
|
+
data.tar.gz: 42bfb0756bda52dd744d8c96f1a8ddbd7a3e6731302176fe0b173d168bec4cba508ceb759f1798680c73ba201ff83d2a42047120a6709ecd00ef1ee20f981281
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.
|
1
|
+
0.8.0
|
data/git-story-workflow.gemspec
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
# -*- encoding: utf-8 -*-
|
2
|
-
# stub: git-story-workflow 0.
|
2
|
+
# stub: git-story-workflow 0.8.0 ruby lib
|
3
3
|
|
4
4
|
Gem::Specification.new do |s|
|
5
5
|
s.name = "git-story-workflow".freeze
|
6
|
-
s.version = "0.
|
6
|
+
s.version = "0.8.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]
|
10
10
|
s.authors = ["Florian Frank".freeze]
|
11
|
-
s.date = "2019-
|
11
|
+
s.date = "2019-05-08"
|
12
12
|
s.description = "Gem abstracting a git workflow\u2026".freeze
|
13
13
|
s.email = "flori@ping.de".freeze
|
14
14
|
s.executables = ["git-story".freeze]
|
data/lib/git/story/app.rb
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
require 'time'
|
2
2
|
require 'open-uri'
|
3
3
|
require 'tins/go'
|
4
|
+
require 'set'
|
4
5
|
|
5
6
|
class Git::Story::App
|
6
7
|
class ::String
|
@@ -168,7 +169,7 @@ class Git::Story::App
|
|
168
169
|
cs.green
|
169
170
|
else
|
170
171
|
cs.yellow
|
171
|
-
end
|
172
|
+
end.italic
|
172
173
|
color_type =
|
173
174
|
case t = story.story_type
|
174
175
|
when 'bug'
|
@@ -180,7 +181,7 @@ class Git::Story::App
|
|
180
181
|
else
|
181
182
|
t
|
182
183
|
end
|
183
|
-
<<~end
|
184
|
+
result = <<~end
|
184
185
|
Id: #{(?# + story.id.to_s).green}
|
185
186
|
Name: #{story.name.inspect.bold}
|
186
187
|
Type: #{color_type}
|
@@ -189,8 +190,11 @@ class Git::Story::App
|
|
189
190
|
Branch: #{current_branch_checked?&.color('#ff5f00')}
|
190
191
|
Labels: #{story.labels.map(&:name).join(' ').on_color(91)}
|
191
192
|
Pivotal: #{story.url}
|
192
|
-
Github: #{github_url(current_branch_checked?)}
|
193
193
|
end
|
194
|
+
if url = github_url(current_branch_checked?)
|
195
|
+
result << "Github: #{url}\n"
|
196
|
+
end
|
197
|
+
result
|
194
198
|
end
|
195
199
|
rescue => e
|
196
200
|
"Getting pivotal story status => #{e.class}: #{e}".red
|
@@ -245,6 +249,20 @@ class Git::Story::App
|
|
245
249
|
capture("git log #{opts} #{ref}..#{last_ref}")
|
246
250
|
end
|
247
251
|
|
252
|
+
command doc: 'List all stories scheduled for next deploy'
|
253
|
+
def deploy_stories(ref = deploy_tags.last, last_ref = nil, rest: [])
|
254
|
+
fetch_commits
|
255
|
+
fetch_tags
|
256
|
+
opts = ([
|
257
|
+
'--color=never',
|
258
|
+
'--pretty=%B'
|
259
|
+
] | rest) * ' '
|
260
|
+
output = capture("git log #{opts} #{ref}..#{last_ref}")
|
261
|
+
pivotal_ids = SortedSet[]
|
262
|
+
output.scan(/\[\s*#\s*(\d+)\s*\]/) { pivotal_ids << $1.to_i }
|
263
|
+
pivotal_ids.map { |pid| status(pid) } * (?┄ * Tins::Terminal.cols << ?\n)
|
264
|
+
end
|
265
|
+
|
248
266
|
command doc: '[REF] output diff since last production deploy tag'
|
249
267
|
def deploy_diff(ref = nil, rest: [])
|
250
268
|
fetch_commits
|
data/lib/git/story/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: git-story-workflow
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Florian Frank
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-05-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: gem_hadar
|