mirror of
https://github.com/SinTan1729/ReVancedBuilder.git
synced 2024-12-26 12:48:36 -06:00
Improved jq syntax
This commit is contained in:
parent
350bf25805
commit
6472f4c01e
1 changed files with 1 additions and 1 deletions
|
@ -93,7 +93,7 @@ for artifact in $artifacts; do
|
||||||
name=$(echo $artifact | cut -d '_' -f2)
|
name=$(echo $artifact | cut -d '_' -f2)
|
||||||
basename=$(echo $name | cut -d '.' -f1)
|
basename=$(echo $name | cut -d '.' -f1)
|
||||||
version_present=$(jq -r ".\"$basename\"" versions.json)
|
version_present=$(jq -r ".\"$basename\"" versions.json)
|
||||||
data=$(jq -r ".tools[] | select(.repository == \"$repo\") | select(.content_type | contains(\"archive\"))" latest_versions.json)
|
data=$(jq -r ".tools[] | select((.repository == \"$repo\") and (.content_type | contains(\"archive\")))" latest_versions.json)
|
||||||
version=$(echo "$data" | jq -r '.version')
|
version=$(echo "$data" | jq -r '.version')
|
||||||
if [[ ${version_present//[!0-9]/} -lt ${version//[!0-9]/} || ! -f $name ]]; then
|
if [[ ${version_present//[!0-9]/} -lt ${version//[!0-9]/} || ! -f $name ]]; then
|
||||||
echo "Downloading $name" | tee -a build.log
|
echo "Downloading $name" | tee -a build.log
|
||||||
|
|
Loading…
Reference in a new issue