git-story-workflow 1.2.0 → 1.3.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 36b917809872cfe428b4919698d7c9fc4cfa5ae9fee374ae9c3b893b5061080c
4
- data.tar.gz: a44657b9ce55dd5fec18f68abc04109e49ee17e44e76e490b6e4bcfe61585d7d
3
+ metadata.gz: 63e47013d8d5c62bf7f3b02c334ab8a6cfb6e200d54506042a8552005fabcd03
4
+ data.tar.gz: 23b3d417eb765ec8d842a06c927c14c3bc79c9e45a488bb1be395ed35ff856e3
5
5
  SHA512:
6
- metadata.gz: a043895d4a9e6057d243e5447eec1668e8c05a0190abd60cfe443e2f0c59784c9ed10d7865a1c04dbb8687889b7c480d0c0b08f6307d27776ccee623c577c0e0
7
- data.tar.gz: 5a5020e9b44229ea153aeaa8f97eb83bf54a65567774eb2adb7ad1e01e12ed1df802c713412d5179029b2fb10ced2226a7b2752db040d005ccb668fd9dade5f6
6
+ metadata.gz: fe79a45d3ba9663fa4b7240fc13e6379b4847282669333ee89c44012226fce6179064152b5c6b345ed57a89fc85e6d1c3fc55e6e561e5a81ef8543be1203bb47
7
+ data.tar.gz: f710599f822a1711c4fc5f7c7731db03b9fbed0e298e3f15fdf4304654c4f5ac20bbf955f51a5c2984eae49db6150f960a3fb43b479272253e5c36141b368ad3
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.2.0
1
+ 1.3.0
@@ -1,14 +1,14 @@
1
1
  # -*- encoding: utf-8 -*-
2
- # stub: git-story-workflow 1.2.0 ruby lib
2
+ # stub: git-story-workflow 1.3.0 ruby lib
3
3
 
4
4
  Gem::Specification.new do |s|
5
5
  s.name = "git-story-workflow".freeze
6
- s.version = "1.2.0"
6
+ s.version = "1.3.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 = "2021-05-04"
11
+ s.date = "2021-05-21"
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
@@ -286,7 +286,7 @@ class Git::Story::App
286
286
  command doc: '[BRANCH] open branch on github'
287
287
  def github(branch = current(check: false))
288
288
  if url = github_url(branch)
289
- system "open #{url.inspect}"
289
+ sh "open #{url.inspect}"
290
290
  end
291
291
  nil
292
292
  end
@@ -295,14 +295,28 @@ class Git::Story::App
295
295
  def pivotal(branch = current(check: true))
296
296
  if story_id = branch&.[](/_(\d+)\z/, 1)&.to_i
297
297
  story_url = fetch_story(story_id)&.url
298
- system "open #{story_url}"
298
+ sh "open #{story_url}"
299
299
  end
300
300
  nil
301
301
  end
302
302
 
303
303
  command doc: 'open project on semaphore'
304
304
  def semaphore
305
- system "open #{complex_config.story.semaphore_project_url}"
305
+ sh "open #{complex_config.story.semaphore_project_url}"
306
+ nil
307
+ end
308
+
309
+ command doc: '[REF] create a hotfix branch from REF'
310
+ def hotfix(ref = nil)
311
+ if ref
312
+ start_point = ref
313
+ elsif tag = tags.last
314
+ start_point = tag_name(tag)
315
+ else
316
+ fail 'no last deployment tag found'
317
+ end
318
+ branch = "hotfix_#{start_point}"
319
+ sh "git checkout -b #{branch.inspect} #{start_point.inspect}"
306
320
  nil
307
321
  end
308
322
 
@@ -394,7 +408,7 @@ class Git::Story::App
394
408
  end
395
409
  loop do
396
410
  r = block.()
397
- system('clear')
411
+ sh 'clear'
398
412
  start = Time.now
399
413
  puts r
400
414
  refresh_at = start + seconds
@@ -1,6 +1,6 @@
1
1
  module Git::Story
2
2
  # Git::Story version
3
- VERSION = '1.2.0'
3
+ VERSION = '1.3.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,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: git-story-workflow
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.3.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: 2021-05-04 00:00:00.000000000 Z
11
+ date: 2021-05-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gem_hadar