Skip to content

Commit

Permalink
feat(update-lockfile): Exit 1 if lockfile was updated
Browse files Browse the repository at this point in the history
  • Loading branch information
RasmusSkytte committed Jul 26, 2024
1 parent d0c58ff commit b57d98d
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions .github/workflows/update-lockfile.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -52,5 +52,10 @@ jobs:
git pull --rebase origin ${{ inputs.branch_name }}
git stash list | grep stash@{0} && git stash pop || echo "No stash to pop"
git add pak.lock || echo "No pak.lock to add"
git commit -m "chore: Update pak.lock" || echo "No changes to commit"
git push origin ${{ inputs.branch_name }}
if git commit -m "chore: Update pak.lock"; then
git push origin ${{ inputs.branch_name }}
echo "Changes committed. Failing the job to prevent further jobs."
exit 1
else
echo "No changes to commit"
fi

0 comments on commit b57d98d

Please sign in to comment.