Skip to content

Commit f2cf743

Browse files
giancosta86github-actions[bot]
authored andcommitted
In tag-and-release, discard the local changes to the Git repository before merging the PR
1 parent 40bb64c commit f2cf743

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

actions/tag-and-release/action.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,13 @@ runs:
155155
echo "🔁Pull request base SHA: '$pullRequestBaseSha'"
156156
echo "🔁Pull request head SHA: '$pullRequestHeadSha'"
157157
158+
- name: Reset any Git local change
159+
shell: bash
160+
run: |
161+
echo "⏱️Discarding local changes to the Git repository..."
162+
git reset --hard HEAD
163+
echo "✅Git repository successfully reset"
164+
158165
- name: Fetch Git log
159166
shell: bash
160167
run: |

0 commit comments

Comments
 (0)