ci(version bump): only increase version if it was changed

This commit is contained in:
Nicolas Meienberger 2024-05-19 14:01:49 +02:00
parent c63e20c105
commit 38068c87af

View File

@ -26,6 +26,7 @@ do
current_config_version=$(jq -r '.version' "$config_file")
echo "Current config version: $current_config_version"
if [[ "$current_config_version" != "$trimmed_version" ]]; then
# Update the version in config.json
contents="$(jq --arg trimmed_version "$trimmed_version" '.version=$trimmed_version' "$config_file")"
echo "${contents}" > "$config_file"
@ -53,4 +54,5 @@ do
echo "${contents}" > "$config_file"
npx prettier "$config_file" --write
fi
fi
done