git_reflow 0.9.6 → 0.9.7

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: 3f15edd7ea0d9df95980438cf9e846bd6b3e07829ef05adcc63c7b548c55c623
4
- data.tar.gz: f315bc14d8ce7873db9f3e4708da9db581bec1bff63d2302465eb356450a2196
3
+ metadata.gz: 1049ee579917beb9c33f04ccb87cd8e285a29dba2afcea18e2719702f601d82f
4
+ data.tar.gz: a4693da0d8bfac1e780968c97186824162739e1f01d32801ff13cf27ff502f8b
5
5
  SHA512:
6
- metadata.gz: bf83e0671b38cd6b3e2f1a008068ad038cee28177ead79a1646994987b0e24141aeb41b0ee191e3856f7f0032df703b66b6a08e41949e319e68ad7dbea9e0bc1
7
- data.tar.gz: 948128297b7ba1a38476fb48a81e1f238745a04966295e8506556cf61c1efacc32a98ea8d2966af43ffaa09a536c03790b6b04f129f65bab779ddfd5e9eeb5ed
6
+ metadata.gz: 32a82c47a85c4944c0b0dc467cdf077f6b684d7139fd7185944dc6f2b6fd19debf4610011dd18ba6261df9ae435ac8de3b89bfb3a81102c28937f509664bde29
7
+ data.tar.gz: cb294516aca558b9debcf7b4ca0255228afc686a85c552a6f8a6ac4b4a52833a560e42ca09d7f36652ed281aaff3766e9d10dfa5e9e742f8169c186a85be91aa
data/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Changelog
2
2
 
3
+ ## [v0.9.7](https://github.com/reenhanced/gitreflow/tree/v0.9.7) (2022-02-20)
4
+
5
+ [Full Changelog](https://github.com/reenhanced/gitreflow/compare/v0.9.6...HEAD)
6
+
7
+ **Bug fixes:**
8
+
9
+ - Correctly parse command line flag and switch values when no help docs are provided
10
+
3
11
  ## [v0.9.6](https://github.com/reenhanced/gitreflow/tree/v0.9.6) (2021-11-05)
4
12
 
5
13
  [Full Changelog](https://github.com/reenhanced/gitreflow/compare/v0.9.5...HEAD)
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- git_reflow (0.9.6)
4
+ git_reflow (0.9.7)
5
5
  bundler (>= 1.10.0)
6
6
  codenamev_bitbucket_api (= 0.4.1)
7
7
  colorize (>= 0.8.1)
@@ -95,17 +95,17 @@ GEM
95
95
  concurrent-ruby (~> 1.0)
96
96
  jwt (2.3.0)
97
97
  method_source (1.0.0)
98
- mini_portile2 (2.6.1)
98
+ mini_portile2 (2.7.1)
99
99
  minitest (5.14.4)
100
100
  multi_json (1.15.0)
101
101
  multi_xml (0.6.0)
102
102
  multipart-post (2.1.1)
103
103
  nio4r (2.5.7)
104
- nokogiri (1.12.5)
105
- mini_portile2 (~> 2.6.1)
104
+ nokogiri (1.13.1)
105
+ mini_portile2 (~> 2.7.0)
106
106
  racc (~> 1.4)
107
- oauth2 (1.4.7)
108
- faraday (>= 0.8, < 2.0)
107
+ oauth2 (1.4.9)
108
+ faraday (>= 0.17.3, < 3.0)
109
109
  jwt (>= 1.0, < 3.0)
110
110
  multi_json (~> 1.3)
111
111
  multi_xml (~> 0.5)
@@ -1,3 +1,3 @@
1
1
  module GitReflow
2
- VERSION = "0.9.6"
2
+ VERSION = "0.9.7"
3
3
  end
@@ -157,6 +157,7 @@ module GitReflow
157
157
  self.commands[name] = params
158
158
  self.command_docs[name] = params
159
159
 
160
+ logger.debug "adding new command '#{name}' with #{defaults.inspect}"
160
161
  self.define_singleton_method(name) do |args = {}|
161
162
  args_with_defaults = {}
162
163
  args.each do |name, value|
@@ -310,13 +311,19 @@ module GitReflow
310
311
  opts.separator "COMMAND OPTIONS:" if docs[:flags].any? || docs[:switches].any?
311
312
 
312
313
  self.commands[name][:flags].each do |flag_name, flag_default|
313
- opts.on("-#{flag_name[0]}", "--#{flag_name} #{flag_name.upcase}", command_docs[name][:flags][flag_name]) do |f|
314
+ # There is a bug in Ruby that will not parse the flag value if no
315
+ # help text is provided. Fallback to the flag name.
316
+ flag_help = command_docs[name][:flags][flag_name] || flag_name
317
+ opts.on("-#{flag_name[0]}", "--#{flag_name} #{flag_name.upcase}", flag_help) do |f|
314
318
  options[kebab_to_underscore(flag_name)] = f || flag_default
315
319
  end
316
320
  end
317
321
 
318
322
  self.commands[name][:switches].each do |switch_name, switch_default|
319
- opts.on("-#{switch_name[0]}", "--[no-]#{switch_name}", command_docs[name][:switches][switch_name]) do |s|
323
+ # There is a bug in Ruby that will not parse the switch value if no
324
+ # help text is provided. Fallback to the switch name.
325
+ switch_help = command_docs[name][:switches][switch_name] || switch_name
326
+ opts.on("-#{switch_name[0]}", "--[no-]#{switch_name}", switch_help) do |s|
320
327
  options[kebab_to_underscore(switch_name)] = s || switch_default
321
328
  end
322
329
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: git_reflow
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.6
4
+ version: 0.9.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Valentino Stoll
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: exe
12
12
  cert_chain: []
13
- date: 2021-11-05 00:00:00.000000000 Z
13
+ date: 2022-02-20 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: appraisal