mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-21 00:25:42 +02:00
ci/update: use if then else
for setting cancelled
step output
The simpler `[[ ]] &&` construct can exit non-zero, causing the workflow to fail.
This commit is contained in:
parent
f584d1d70d
commit
bffee37f57
1 changed files with 7 additions and 1 deletions
8
.github/workflows/update.yml
vendored
8
.github/workflows/update.yml
vendored
|
@ -129,9 +129,15 @@ jobs:
|
|||
(
|
||||
echo "old_rev=$old"
|
||||
echo "new_rev=$new"
|
||||
[[ "$old" = "$new" ]] && echo 'cancelled=1'
|
||||
) >> $GITHUB_OUTPUT
|
||||
|
||||
if [[ "$old" = "$new" ]]; then
|
||||
echo "Old and new revisions are the same"
|
||||
echo 'cancelled=1' >> $GITHUB_OUTPUT
|
||||
else
|
||||
echo "Old and new revisions are different"
|
||||
fi
|
||||
|
||||
- name: Update generated files
|
||||
id: generate
|
||||
if: (!steps.changes.outputs.cancelled) && (inputs.generate || github.event_name == 'schedule')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue