-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
279327f
commit dcc3fa8
Showing
1 changed file
with
28 additions
and
22 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 |
---|---|---|
|
@@ -17,26 +17,32 @@ jobs: | |
fetch-depth: 0 | ||
token: ${{ secrets.GH_TOKEN }} | ||
persist-credentials: false | ||
- name: Sync upstream changes | ||
id: sync | ||
uses: aormsby/[email protected] | ||
with: | ||
target_sync_branch: develop | ||
# REQUIRED 'target_repo_token' exactly like this! | ||
target_repo_token: ${{ secrets.GH_TOKEN }} | ||
upstream_sync_branch: develop | ||
upstream_sync_repo: YoYoGames/GameMaker-Manual | ||
upstream_repo_access_token: ${{ secrets.GH_TOKEN }} | ||
git_config_user: ksuchitra532 | ||
git_config_email: null | ||
git_config_pull_rebase: true | ||
- name: Sync upstream changes | ||
id: sync-lts | ||
uses: aormsby/[email protected] | ||
- name: Merge from upstream | ||
env: | ||
UPSTREAM: YoYoGames/GameMaker-Manual | ||
run: | | ||
git config --global user.name "github-actions" | ||
git config --global user.email "[email protected]" | ||
git --version | ||
# Add upstream remote and fetch | ||
git remote add upstream "https://x-access-token:${{ secrets.GH_TOKEN }}@github.com/${UPSTREAM}.git" | ||
git remote -v | ||
git fetch upstream | ||
# Merge from upstream/develop with merge strategy to keep translation in case of conflicts | ||
git merge -X ours upstream/main-lts | ||
# this is dangerous but will essentially remove any files not staged in the merge | ||
# this is useful since the merge strategy `-X ours` will not handle files where | ||
# they have been deleted on only one branch | ||
# Only use this you're sure that the failing merges fall under this category and are acceptable | ||
# git diff --name-only --diff-filter=U | xargs git rm | ||
git show-ref | ||
- name: Push changes | ||
uses: ad-m/github-push-action@master | ||
with: | ||
target_sync_branch: main-lts | ||
# REQUIRED 'target_repo_token' exactly like this! | ||
target_repo_token: ${{ secrets.GH_TOKEN }} | ||
upstream_sync_branch: main-lts | ||
upstream_sync_repo: YoYoGames/GameMaker-Manual | ||
upstream_repo_access_token: ${{ secrets.GH_TOKEN }} | ||
github_token: ${{ secrets.GH_TOKEN }} | ||
branch: ${{ github.ref }} |