forked from defenseunicorns/uds-core
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from UnicornChance/test
feat: create merge-commit.yaml
- Loading branch information
Showing
1 changed file
with
28 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
name: Update Merge Commit Title | ||
|
||
on: | ||
pull_request: | ||
types: [closed] | ||
|
||
jobs: | ||
update-merge-commit: | ||
if: github.event.pull_request.merged == true && contains(github.event.pull_request.head.ref, 'release-please--branches--main') == false | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v2 | ||
|
||
- name: Configure git | ||
run: | | ||
git config --global user.name "github-actions[bot]" | ||
git config --global user.email "github-actions[bot]@users.noreply.github.com" | ||
- name: Get merge commit SHA | ||
id: get_commit_sha | ||
run: echo "MERGE_COMMIT_SHA=$(git rev-parse HEAD)" >> $GITHUB_ENV | ||
|
||
- name: Update merge commit message | ||
run: | | ||
git commit --amend -m "this is a test" | ||
git push --force |