Update .drone.yml
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Sthope 2023-08-28 19:18:31 +02:00
parent 3346113562
commit e7f5374383

View File

@ -5,16 +5,28 @@ trigger:
release: true release: true
steps: steps:
# - name: checkout - name: checkout
# image: plugins/git image: plugins/git
# settings: settings:
# repo: https://github.com/insignia-live/setup-assistant-release.git repo: https://github.com/insignia-live/setup-assistant-release.git
- name: run - name: run
image: node:14 image: alpine:3.13
commands: commands:
- npm install axios - apk add --no-cache curl jq
- node tools/check_version.js - |
latestReleaseTag=$(curl -s "https://api.github.com/repos/insignia-live/setup-assistant-release/releases/latest" | jq -r '.tag_name')
targetReleaseTag="2023-02-13-1223" # Replace with your target release tag
if [[ "$latestReleaseTag" > "$targetReleaseTag" ]]; then
echo "This pipeline is run because the new release is newer than the one I have."
elif [[ "$latestReleaseTag" = "$targetReleaseTag" ]]; then
echo "The release tag is the same as the target tag."
echo "Running testing step..."
exit 0 # Trigger the testing step
else
echo "The new release is older than the one I have."
fi
when: when:
status: status:
- success - success
@ -25,7 +37,3 @@ steps:
image: alpine image: alpine
commands: commands:
- echo "test" - echo "test"
when:
status:
- success
- changed