squared 0.4.40 → 0.4.42

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: 9274835227b6d4541e223612c12730e6b87af9cd0b8f60e73ce2821301ce2fb3
4
- data.tar.gz: 13049d3adf02a7114a72ded6b73a6d0375fef29a8db43c43ba1e823f92863b42
3
+ metadata.gz: 6e6b403849f7b4bf8d7cbab3a7ec6c31a6231896ec0e3413f5053c1dfbaf9dfa
4
+ data.tar.gz: 6939f1e9faa5b82dd0ebd5ce2fdbc0243862e79b65c7e946bfa59a9d9a462eeb
5
5
  SHA512:
6
- metadata.gz: 634e4c43b25ba777a5009b419276df8c1018dcba79da96f8c8bd7f3499a8f17185de6361b0631e6c9514c0421db3f1005e35b968d94ada0618a1f061f5650e93
7
- data.tar.gz: 74657c33d825ccaec2e6249227a31679f5d6a16aa83e00a0969875f60cd9f90943e40aed095e65baf927197e4c001e828f1f2cd1e2c56efd8c98ee5d23359c8e
6
+ metadata.gz: 488c383693a1779b1ef64ebfc5b97f147f89aaaa5a07cc3f1286ecc6e6a47fa31f722d9bcc134a59ff56a55cb8ba6d4a6c76af084b8fe1c605adf33d4cb69c89
7
+ data.tar.gz: 4f2cdb13799b7c290098d380ab7d83b9053ce393a33ed6aea00f28e0061fc39290e430085c73ad5d0886839f84b8b2728394646b52765fec74d1bd1c6a9530ac
data/CHANGELOG.md CHANGED
@@ -1,5 +1,32 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.4.42] - 2026-09-23
4
+
5
+ ### Fixed
6
+
7
+ - OptionPartition did not strip pre-existing quotes when parsing options.
8
+ - Node command outdated did not strip styling from semver in package.json.
9
+ - Git command show did not recognize object names.
10
+ - Docker destination mounts that are not absolute are treated as errors.
11
+ - Docker source mounts for any named volumes or images were inoperable.
12
+
13
+ ## [0.4.41] - 2026-09-04
14
+
15
+ ### Added
16
+
17
+ - Common base argument SUCCESS for command confirmation was created.
18
+
19
+ ### Changed
20
+
21
+ - Program options prefer using quotes instead of escape.
22
+ - Docker container run arguments with a leading dash are concatenated.
23
+
24
+ ### Fixed
25
+
26
+ - Common prompt method choice did not grep list items.
27
+ - OptionPartition static method strip did not parse flags with dashes.
28
+ - Project base method choice_index did not support multiple selections.
29
+
3
30
  ## [0.4.40] - 2026-08-06
4
31
 
5
32
  ### Changed
@@ -1246,6 +1273,8 @@
1246
1273
 
1247
1274
  - Changelog was created.
1248
1275
 
1276
+ [0.4.42]: https://github.com/anpham6/squared-ruby/releases/tag/v0.4.42
1277
+ [0.4.41]: https://github.com/anpham6/squared-ruby/releases/tag/v0.4.41
1249
1278
  [0.4.40]: https://github.com/anpham6/squared-ruby/releases/tag/v0.4.40
1250
1279
  [0.4.39]: https://github.com/anpham6/squared-ruby/releases/tag/v0.4.39
1251
1280
  [0.4.38]: https://github.com/anpham6/squared-ruby/releases/tag/v0.4.38
@@ -14,6 +14,7 @@ module Squared
14
14
  CHOICE: 25,
15
15
  QUOTE: "'",
16
16
  SPACE: ' => ',
17
+ SUCCESS: 'Success',
17
18
  GRAPH: ['|', '-', '|', '\\', '-'].freeze,
18
19
  BORDER: ['|', '-', '-', '-', '-', '-', '|', '|', '-', '-'].freeze,
19
20
  VIEW: 'view',
@@ -40,7 +40,7 @@ module Squared
40
40
  grep &&= Array(grep).map { |val| Regexp.new(val) }
41
41
  items = []
42
42
  list.each do |val|
43
- next if grep&.none? { |pat| pat.match?(line) }
43
+ next if grep&.none? { |pat| pat.match?(val) }
44
44
 
45
45
  items << val.to_s.chomp
46
46
  puts "#{items.size.to_s.rjust(2)}. #{val}"
@@ -122,7 +122,7 @@ module Squared
122
122
  end
123
123
 
124
124
  def env_key(*val)
125
- val.join('_').gsub(/\W+/, '_').upcase
125
+ val.join('_').sub(/\A\d+\W*/, '__').gsub(/\W+/, '_').upcase
126
126
  end
127
127
 
128
128
  def env_value(key, default = '', suffix: nil, strict: false)
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Squared
4
- VERSION = '0.4.40'
4
+ VERSION = '0.4.42'
5
5
  end
@@ -1300,7 +1300,7 @@ module Squared
1300
1300
  end
1301
1301
 
1302
1302
  def print_success(*)
1303
- puts 'Success'
1303
+ puts ARG[:SUCCESS]
1304
1304
  end
1305
1305
 
1306
1306
  def print_error(*args, loglevel: Logger::WARN, **kwargs)
@@ -1681,7 +1681,10 @@ module Squared
1681
1681
  if accept
1682
1682
  hint = Array(ret).map { |val| sub_style(val, styles: theme[:inline]) }.join(', ')
1683
1683
  accept = Array(accept).map { |val| Array(val) }
1684
- ret = Array(ret) if accept.any? { |val| val[1] == true }
1684
+ if accept.any? { |val| val[1] == true }
1685
+ ret = [ret]
1686
+ multiple = -1
1687
+ end
1685
1688
  loop do
1686
1689
  item = accept.first
1687
1690
  d, e = item[2] ? ['Y', '[Y/n]'] : ['N', '[y/N]']
@@ -1698,7 +1701,7 @@ module Squared
1698
1701
  exit 1 unless accept.empty?
1699
1702
  end
1700
1703
  if values
1701
- ret = Array(ret)
1704
+ ret = [ret] unless accept && multiple == -1
1702
1705
  Array(values).each do |val|
1703
1706
  if val.is_a?(Array)
1704
1707
  val, force = val
@@ -16,18 +16,18 @@ module Squared
16
16
  cgroup-parent=b iidfile=p label=q network=b no-cache-filter=b o|output=q platform=q
17
17
  q|quiet secret=qq shm-size=b ssh=qq t|tag=b target=b ulimit=q].freeze,
18
18
  bake: %w[print list=q set=q].freeze,
19
- shared: %w[check load no-cache pull push allow=q call=b? f|file=p metadata-file=p progress=b provenance=q
20
- sbom=q].freeze
19
+ shared: %w[check load no-cache pull push allow=qq call=b? f|file=p metadata-file=p progress=b provenance=b?
20
+ sbom=b?].freeze
21
21
  }.freeze,
22
22
  compose: {
23
- common: %w[all-resources compatibility dry-run ansi=b env-file=p f|file=p parallel=n profile=b progress=b
24
- project-directory=p p|project-name=e].freeze,
23
+ common: %w[1 all-resources compatibility dry-run ansi=b env-file=p f|file=p parallel=n profile=b progress=b
24
+ project-directory=p p|project-name=b].freeze,
25
25
  build: %w[check no-cache print pull push with-dependencies q|quiet build-arg=qq builder=b m|memory=b
26
26
  provenance=q sbom=q ssh=qq].freeze,
27
- exec: %w[d|detach privileged e|env=qq index=i T|no-TTY=b? user=e w|workdir=q].freeze,
27
+ exec: %w[d|detach privileged e|env=qq index=i T|no-tty=!? user=b w|workdir=q].freeze,
28
28
  run: %w[build d|detach no-deps q|quiet quiet-build quiet-pull remove-orphans rm P|service-ports use-aliases
29
29
  cap-add=b cap-drop=b entrypoint=q e|env=qq env-from-file=p i|interactive=b? l|label=q name=b
30
- T|no-TTY=b? p|publish=q pull=b u|user=e v|volume=q w|workdir=q].freeze,
30
+ T|no-tty=!? p|publish=q pull=b u|user=b v|volume=qq w|workdir=q].freeze,
31
31
  up: %w[abort-on-container-exit abort-on-container-failure always-recreate-deps attach-dependencies build
32
32
  d|detach force-recreate menu no-build no-color no-deps no-log-prefix no-recreate no-start quiet-build
33
33
  quiet-pull remove-orphans V|renew-anon-volumes timestamps wait w|watch y|yes attach=b
@@ -36,9 +36,9 @@ module Squared
36
36
  }.freeze,
37
37
  container: {
38
38
  create: %w[init i|interactive no-healthcheck oom-kill-disable privileged P|publish-all q|quiet read-only
39
- rm t|tty use-api-socket add-host=q annotation=q a|attach=b blkio-weight=i blkio-weight-device=i
40
- cap-add=b cap-drop=b cgroup-parent=b cgroupns=b cidfile=p device=q device-cgroup-rule=q
41
- device-read-bps=q device-read-iops=q device-write-bps=q device-write-iops=q
39
+ rm t|tty=!? use-api-socket add-host=q annotation=q a|attach=b blkio-weight=i
40
+ blkio-weight-device=i cap-add=b cap-drop=b cgroup-parent=b cgroupns=b cidfile=p device=q
41
+ device-cgroup-rule=q device-read-bps=q device-read-iops=q device-write-bps=q device-write-iops=q
42
42
  disable-content-trust=b? dns=q dns-option=q dns-search=q domainname=b entrypoint=q e|env=qq
43
43
  env-file=p expose=q gpus=q group-add=b health-cmd=q health-interval=b health-retries=i
44
44
  health-start-interval=q health-start-period=q health-timeout=q hostname=q io-maxbandwidth=b
@@ -47,13 +47,14 @@ module Squared
47
47
  memory-swap=n memory-swappiness=n mount=qq name=b network=b network-alias=b oom-score-adj=b
48
48
  pid=b pids-limit=n platform=q p|publish=q pull=b restart=b runtime=b security-opt=q shm-size=b
49
49
  stop-signal=b stop-timeout=i storage-opt=q sysctl=q tmpfs=q ulimit=q u|user=b userns=b uts=b
50
- v|volume=q volume-driver=b volumes-from=b w|workdir=q].freeze,
50
+ v|volume=qq volume-driver=b volumes-from=b w|workdir=q].freeze,
51
51
  run: %w[d|detach detach-keys=q sig-proxy=b?].freeze,
52
52
  update: %w[blkio-weight=i cpu-period=i cpu-quota=i cpu-rt-period=i cpu-rt-runtime=i c|cpu-shares=i cpus=f
53
53
  cpuset-cpus=b cpuset-mems=b m|memory=b memory-reservation=b memory-swap=b pids-limit=n
54
54
  restart=q].freeze,
55
- exec: %w[d|detach i|interactive privileged t|tty detach-keys=q e|env=qq env-file=p user=e
55
+ exec: %w[d|detach i|interactive privileged t|tty=!? detach-keys=q e|env=qq env-file=p user=b
56
56
  w|workdir=q].freeze,
57
+ rm: %w[f|force l|link v|volumes].freeze,
57
58
  commit: %w[a|author=q c|change=q m|message=q pause=b?].freeze,
58
59
  inspect: %w[s|size f|format=q type=b].freeze,
59
60
  start: %w[a|attach i|interactive detach-keys=q].freeze,
@@ -76,10 +77,10 @@ module Squared
76
77
  VAL_DOCKER = {
77
78
  run: {
78
79
  common: %w[source src destination dst target readonly ro].freeze,
79
- bind: %w[bind-propagation].freeze,
80
+ bind: %w[bind-create-src bind-propagation].freeze,
80
81
  volume: %w[volume-subpath volume-nocopy volume-opt].freeze,
81
82
  tmpfs: %w[tmpfs-size tmpfs-mode].freeze,
82
- image: %w[image-path].freeze
83
+ image: %w[image-subpath].freeze
83
84
  }.freeze
84
85
  }.freeze
85
86
  private_constant :COMPOSEFILE, :BAKEFILE, :OPT_DOCKER, :VAL_DOCKER
@@ -388,20 +389,30 @@ module Squared
388
389
  end
389
390
  end
390
391
  case k
391
- when 'readonly', 'ro'
392
- args << k
392
+ when 'readonly', 'ro', 'volume-nocopy', 'bind-create-src'
393
+ args << k if %w[bind volume].include?(type)
393
394
  next
394
- when 'source', 'src', 'destination', 'dst', 'target', 'volume-subpath', 'image-path'
395
- v = basepath v
395
+ when 'source', 'src', 'destination', 'dst', 'target', 'volume-subpath', 'image-subpath'
396
+ raise_error ArgumentError, "no path value: #{k}", hint: flag unless v
397
+ case k
398
+ when 'source', 'src'
399
+ if type == 'bind'
400
+ v = basepath v
401
+ elsif type == 'tmpfs'
402
+ next
403
+ end
404
+ when 'destination', 'dst', 'target'
405
+ puts log_message("path is not absolute: #{v}", subject: from, hint: k) unless v.start_with?('/')
406
+ end
396
407
  v = shell_quote(v, option: false, force: false) if q == ''
397
408
  end
398
409
  args << "#{k}=#{q + v + q}"
399
410
  elsif verbose
400
- log_message(Logger::INFO, 'unrecognized option', subject: from, hint: k)
411
+ puts log_message(Logger::INFO, 'unrecognized option', subject: from, hint: k)
401
412
  end
402
413
  end
403
414
  raise_error('missing type', hint: flag) unless type
404
- cmd << "--mount type=#{type},#{args.join(',')}"
415
+ op << "--mount type=#{type},#{args.join(',')}"
405
416
  end
406
417
  end
407
418
  append_command(flag, id || tagmain, op.extras)
@@ -410,7 +421,7 @@ module Squared
410
421
  op.append(escape: true, strip: /^:/)
411
422
  when :commit
412
423
  latest = op.shift || tagmain
413
- cmd << id << latest
424
+ op << id << latest
414
425
  raise_error("unknown args: #{op.join(', ')}", hint: flag) unless op.empty?
415
426
  return unless confirm_command(cmd.to_s, title: from, target: id, as: latest)
416
427
 
@@ -607,8 +618,22 @@ module Squared
607
618
  when :exec
608
619
  raise_error('no command args', hint: flag) if list.empty?
609
620
  end
610
- target << val << list.shift
611
- target << list.join(' && ') unless list.empty?
621
+ target << val
622
+ case list.first
623
+ when '--'
624
+ target.merge(list.drop(1))
625
+ when /\A(--|&&)(\s|\z)/
626
+ target.merge(list)
627
+ else
628
+ target << list.shift
629
+ unless list.empty?
630
+ if list.first.start_with?('-')
631
+ target.merge(list)
632
+ else
633
+ target << list.join(' && ')
634
+ end
635
+ end
636
+ end
612
637
  end
613
638
 
614
639
  def append_file(type, target: @session, index: 2)
@@ -783,7 +808,7 @@ module Squared
783
808
  end
784
809
  cmd.merge(Array(out).map! { |val| parse.call(val) })
785
810
  cmd << args
786
- print_success if success?(run(cmd)) && ctx.match?(/\A(?:network|tag|save)/)
811
+ print_success if success?(run(cmd, { 'NO_COLOR' => 'true' })) && ctx.match?(/\A(?:network|tag|save)/)
787
812
  end
788
813
  end
789
814
 
@@ -171,7 +171,7 @@ module Squared
171
171
  }.freeze,
172
172
  fetch: {
173
173
  base: %w[multiple progress P|prune-tags refetch stdin u|update-head-ok recurse-submodules-default=b].freeze,
174
- pull: %w[4 6 n t a|append atomic dry-run f|force k|keep negotiate-only prefetch p|prune q|quiet
174
+ pull: %w[n t 4|ipv4 6|ipv6 a|append atomic dry-run f|force k|keep negotiate-only prefetch p|prune q|quiet
175
175
  set-upstream unshallow update-shallow v|verbose deepen=i depth=i j|jobs=i negotiation-tip=q
176
176
  recurse-submodules=v refmap=q o|server-option=q shallow-exclude=b shallow-since=v
177
177
  upload-pack=q].freeze
@@ -207,7 +207,7 @@ module Squared
207
207
  ita-invisible-in-index minimal name-only name-status no-color-moved-ws no-prefix no-renames numstat
208
208
  patch-with-raw patch-with-stat patience pickaxe-all pickaxe-regex raw shortstat summary a|text
209
209
  abbrev=i? anchored=q break-rewrites=b? color=b color-moved=b color-moved-ws=b color-words=q?
210
- diff-algorithm=b diff-filter=e? X|dirstat=b? dirstat-by-file=b? dst-prefix=q find-copies=i?
210
+ diff-algorithm=b diff-filter=q? X|dirstat=b? dirstat-by-file=b? dst-prefix=q find-copies=i?
211
211
  find-object=b find-renames=b? ignore-matching-lines=q ignore-submodules=b? inter-hunk-context=i
212
212
  line-prefix=q output=p output-indicator-context=q output-indicator-new=q output-indicator-old=q
213
213
  relative=p rotate-to=p skip-to=p src-prefix=q stat=b? stat-count=i stat-width=i stat-name-width=i
@@ -262,7 +262,7 @@ module Squared
262
262
  checkout: %w[overwrite-ignore guess overlay progress recurse-submodules track].freeze,
263
263
  fetch: {
264
264
  base: %w[auto-gc auto-maintenance write-commit-graph write-fetch-head].freeze,
265
- pull: %w[all ipv4 ipv6 recurse-submodules show-forced-updates tags].freeze
265
+ pull: %w[all recurse-submodules show-forced-updates tags].freeze
266
266
  },
267
267
  log: {
268
268
  base: %w[decorate mailmap merges use-mailmap].freeze,
@@ -1668,7 +1668,7 @@ module Squared
1668
1668
  cmd << '--textconv'
1669
1669
  append_value(files.flat_map { |val| Dir[val] }
1670
1670
  .select { |val| projectpath?(val) }
1671
- .map! { |val| shell_quote("HEAD:#{val}") })
1671
+ .map! { |val| "HEAD:#{val}" })
1672
1672
  source(banner: false)
1673
1673
  return
1674
1674
  when :oneline
@@ -1682,10 +1682,11 @@ module Squared
1682
1682
  else
1683
1683
  opts << format if format
1684
1684
  end
1685
- op = OptionPartition.new(opts, OPT_GIT[:show] + OPT_GIT[:diff][:show] + OPT_GIT[:log][:diff], cmd,
1685
+ list = OPT_GIT[:show] + OPT_GIT[:diff][:show] + collect_hash(OPT_GIT[:log], pass: [:base])
1686
+ op = OptionPartition.new(opts, list, cmd,
1686
1687
  project: self,
1687
1688
  no: OPT_GIT[:no][:show] + collect_hash(OPT_GIT[:no][:log], pass: [:base]))
1688
- op.append(delim: true)
1689
+ op.append
1689
1690
  source(exception: false, banner: flag != :oneline)
1690
1691
  end
1691
1692
 
@@ -1717,7 +1718,7 @@ module Squared
1717
1718
  op.add_quote(remote) if remote
1718
1719
  out, banner, from = source(io: true)
1719
1720
  print_item banner
1720
- ret = write_lines(out, grep: op.extras, prefix: "refs/#{flag}/")
1721
+ ret = write_lines(out, grep: op.extras)
1721
1722
  list_result(ret, flag.to_s, grep: op.extras, banner: banner, from: from)
1722
1723
  end
1723
1724
 
@@ -603,7 +603,7 @@ module Squared
603
603
  capture
604
604
  else
605
605
  modified += 1
606
- "#{$1}\"#{$2 || (d == 1 && e ? '^' : '')}#{c}\""
606
+ "#{$1}\"#{$2 || (d == 1 && e ? '^' : '')}#{strip_style(c)}\""
607
607
  end
608
608
  end
609
609
  end
@@ -159,7 +159,7 @@ module Squared
159
159
  log.warn "run script #{n} of #{list.size} (out of range)"
160
160
  end
161
161
  else
162
- case (index > 1 && poetry? : 0 : index)
162
+ case (index > 1 && poetry? ? 0 : index)
163
163
  when 0
164
164
  found |= 1
165
165
  run(session_output('poetry', 'run', val), from: :run)
@@ -542,7 +542,7 @@ module Squared
542
542
  case flag
543
543
  when :hatch, :twine
544
544
  if op.empty?
545
- op.push("#{dist.call}/*")
545
+ op.push(dist.call.join('*'))
546
546
  else
547
547
  op.map! { |val| basepath(val) }
548
548
  end
@@ -74,7 +74,25 @@ module Squared
74
74
  return [] unless val
75
75
 
76
76
  val = shell_split val if val.is_a?(String)
77
- val.map { |s| s.sub(OPT_SINGLE, '\1=\2').sub(OPT_VALUE, '\1=\2').sub(OPT_NAME, '\2') }.reject(&:empty?)
77
+ ret = []
78
+ pass = -1
79
+ (args = Array(val)).each_with_index do |s, i|
80
+ next if s.empty? || pass == i
81
+
82
+ if s == '--'
83
+ ret << s << args[i.succ..-1].join(' ')
84
+ break
85
+ end
86
+ next ret << s unless s.start_with?('-')
87
+
88
+ if !s.include?('=') && (j = args[i.succ]) && !j.start_with?('-')
89
+ ret << "#{s.sub(/^-{1,2}/, '')}=#{j}"
90
+ pass = i.succ
91
+ else
92
+ ret << s.sub(OPT_SINGLE, '\1=\2').sub(OPT_VALUE, '\1=\2').sub(OPT_NAME, '\2')
93
+ end
94
+ end
95
+ ret
78
96
  end
79
97
 
80
98
  def select(list, bare: true, no: true, single: false, double: false)
@@ -103,7 +121,11 @@ module Squared
103
121
  end
104
122
 
105
123
  def pattern?(val)
106
- val.match?(/(?:\A\^|\$\z)/) || val.match?(/(?:\.[*+]|\(\?:|\\[dsw]|\[.+\]|\{\d+,?\d*})/)
124
+ Regexp.new(val)
125
+ val.start_with?('\A', '^') || val.end_with?('\z', '$') ||
126
+ val.match?(/[.)][*+?]|\(\?[:=!><]|\\[dsw\d]|\[.+\]|\{\d+,?\d*\}/i)
127
+ rescue RegexpError
128
+ false
107
129
  end
108
130
 
109
131
  private
@@ -233,7 +255,7 @@ module Squared
233
255
  end
234
256
  numtype = [
235
257
  [i, /\A\d+\z/],
236
- [f, /\A\d*(?:\.\d+)?\z/],
258
+ [f, /\A(\d+(\.\d*)?|\d*\.\d+)\z/],
237
259
  [si, /\A-?\d+\z/]
238
260
  ].freeze
239
261
  numcheck = ->(k, v) { numtype.any? { |flag, pat| flag.include?(k) && pat.match?(v) } }
@@ -252,23 +274,27 @@ module Squared
252
274
  if opt =~ OPT_VALUE
253
275
  key = $1
254
276
  val = $2
277
+ if val =~ /\A(["'])(.+)\1\z/
278
+ val = $2
279
+ double = $1 == '"'
280
+ end
255
281
  merge = m.include?(key)
256
282
  if e.include?(key)
257
- add shell_option(key, val, merge: merge)
283
+ add shell_option(key, val, double: double, merge: merge)
258
284
  elsif q.include?(key)
259
- add quote_option(key, val, double: qq.include?(key), merge: merge)
285
+ add quote_option(key, val, double: double || qq.include?(key), merge: merge)
260
286
  elsif p.include?(key)
261
- if val.match?(/\A(["']).+\1\z/)
262
- add shell_option(key, val, escape: false, merge: merge)
287
+ if !double.nil?
288
+ add shell_option(key, val, double: double, merge: merge, escape: false)
263
289
  elsif path
264
290
  add quote_option(key, path + val, merge: merge)
265
291
  else
266
292
  push opt
267
293
  end
268
294
  elsif b.include?(key) || (bl.include?(key) && %w[true false].include?(val)) || numcheck.call(key, val)
269
- add basic_option(key, val, merge: merge)
295
+ add basic_option(key, val, double: double, merge: merge)
270
296
  elsif merge
271
- add basic_option(key, val, merge: true)
297
+ add basic_option(key, val, double: double, merge: true)
272
298
  else
273
299
  push opt
274
300
  end
@@ -237,7 +237,7 @@ module Squared
237
237
 
238
238
  def repo_run(cmd, exception: false)
239
239
  puts log_message(Logger::INFO, cmd, subject: main, hint: root) if verbose
240
- Common::System.shell(cmd, chdir: root, exception: exception)
240
+ Common::System.shell(cmd, chdir: root, exception: exception || %w[1 true].include?(env('REPO_FAIL')))
241
241
  end
242
242
 
243
243
  def repo_bin
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: squared
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.40
4
+ version: 0.4.42
5
5
  platform: ruby
6
6
  authors:
7
7
  - An Pham
@@ -125,7 +125,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
125
125
  - !ruby/object:Gem::Version
126
126
  version: '0'
127
127
  requirements: []
128
- rubygems_version: 4.0.15
128
+ rubygems_version: 4.0.21
129
129
  specification_version: 4
130
130
  summary: Rake task generator for managing multi-language workspaces.
131
131
  test_files: []