File tree Expand file tree Collapse file tree 1 file changed +10
-13
lines changed Expand file tree Collapse file tree 1 file changed +10
-13
lines changed Original file line number Diff line number Diff line change @@ -242,19 +242,16 @@ check-size:
242
242
etc/ check-package-size.sh
243
243
244
244
# Report the Minimum Supported Rust Version (the `rust-version` of `gix`) in X.Y.Z form
245
- msrv :
246
- set -eu; \
247
- query=' .packages[] | select(.name == "gix") | .rust_version' ; \
248
- value=" $({{ j }} get-metadata " $query" )" ; \
249
- case " $value" in \
250
- *.*.*) \
251
- echo " $value" ;; \
252
- *.*) \
253
- echo " $value.0" ;; \
254
- *) \
255
- echo " No '.' in gix rust-version '$value'" >&2 ; \
256
- exit 1 ;; \
257
- esac
245
+ msrv : (get-metadata '''
246
+ (.packages[] | select(.name == " gix" ) | .rust_version | tostring) as $v |
247
+ if ($v | test(" ^[0-9]+\\ .[0-9]+\\ .[0-9]+$" )) then
248
+ $v
249
+ elif ($v | test(" ^[0-9]+\\ .[0-9]+$" )) then
250
+ $v + " .0"
251
+ else
252
+ error (" Unrecognized rust-version format: " + $v)
253
+ end
254
+ ''' )
258
255
259
256
# Regenerate the MSRV badge SVG
260
257
msrv-badge:
You can’t perform that action at this time.
0 commit comments