Skip to content

Commit

Permalink
pop the last stash off the stack if it exists
Browse files Browse the repository at this point in the history
  • Loading branch information
qrkourier committed Jan 16, 2024
1 parent b56acfd commit d889adb
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,10 @@ if [ -n "$(git status --porcelain)" ]; then
git stash
git fetch "$INPUT_REMOTE" "$GITHUB_REF:actions-x-temp-branch"
git switch actions-x-temp-branch
git stash pop
STASH_NAME=$(git stash list | awk -F: '/stash@/{print $1}')
if [ -n "$STASH_NAME" ]; then
git stash pop
fi
git add $INPUT_FILES -v
git commit -m "$INPUT_MESSAGE"
else
Expand Down

0 comments on commit d889adb

Please sign in to comment.