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

Update action #1656

Merged
merged 1 commit into from
Nov 1, 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
38 changes: 21 additions & 17 deletions .github/workflows/patch-minor-merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,24 +25,28 @@ jobs:
token: PAT_TOKEN

- name: Configure Git
env:
TOKEN: ${{ secrets.PAT_TOKEN }}
run: |
git config user.name "GitHub Actions Bot"
git config user.email "[email protected]"
git config user.name "GitHub Actions Bot"
git config user.email "[email protected]"
git config --global url."https://[email protected]/".insteadOf "https://github.com/"

- name: Merge patch into minor
run: |
# Fetch all branches
git fetch origin

# Checkout minor branch
git checkout minor
git pull origin minor

# Merge patch into minor
if git merge origin/patch --no-edit; then
git push origin minor
echo "Successfully merged patch into minor"
else
echo "Merge conflicts detected. Manual intervention required."
exit 1
fi
echo "Fetching branches..."
git fetch origin

echo "Checking out minor branch..."
git checkout minor
git pull origin minor

echo "Attempting merge..."
if git merge origin/patch --no-edit; then
echo "Merge successful, pushing changes..."
git push origin minor
echo "Successfully merged patch into minor"
else
echo "Merge conflicts detected. Manual intervention required."
exit 1
fi
Loading