Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix release branch #121

Merged
merged 1 commit into from
Jun 11, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .github/workflows/create_release_branch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,15 @@ jobs:
- name: Branch already exists
if: ${{env.branch_exists == 'true'}}
run: echo "message=Branch `${{env.release_branch}}` already exists." >> $GITHUB_ENV
- name: Commit Empty commit and push changes
run: |
git config --global user.email "[email protected]"
git config --global user.name "GitHub Actions"
Comment on lines +36 to +37
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Configure Git user locally instead of globally.

- git config --global user.email "[email protected]"
- git config --global user.name "GitHub Actions"
+ git config user.email "[email protected]"
+ git config user.name "GitHub Actions"

This change ensures that the configuration does not affect other actions running in the same runner.

Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
git config --global user.email "[email protected]"
git config --global user.name "GitHub Actions"
git config user.email "[email protected]"
git config user.name "GitHub Actions"

git checkout ${{env.release_branch}}
git add .
git pull origin ${{ env.release_branch }}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use git pull --rebase to avoid unnecessary merge commits.

- git pull origin ${{ env.release_branch }}
+ git pull --rebase origin ${{ env.release_branch }}

This change helps maintain a cleaner commit history by rebasing local changes on top of the fetched branch.

Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
git pull origin ${{ env.release_branch }}
git pull --rebase origin ${{ env.release_branch }}

git commit --allow-empty -m "Release branch creation commit"
git push origin ${{ env.release_branch }}
- name: Send message on Slack
uses: archive/[email protected]
id: notify
Expand Down
Loading