forked from mpv-player/mpv
-
Notifications
You must be signed in to change notification settings - Fork 1
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
83bb498
commit 85d63aa
Showing
1 changed file
with
34 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,34 @@ | ||
#更新fork | ||
name: update fork | ||
|
||
on: | ||
repository_dispatch: | ||
workflow_dispatch: | ||
schedule: | ||
- cron: '50 7 * * *' #设置定时任务 | ||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
token: ${{ secrets.WORKFLOW_TOKEN }} | ||
- name: Set env | ||
run: | | ||
git config user.name "github-actions[bot]" | ||
git config user.email "41898282+github-actions[bot]@users.noreply.github.com" | ||
- name: Update fork master | ||
run: | | ||
git remote add upstream https://github.com/mpv-player/mpv.git | ||
git remote -v | ||
git fetch upstream | ||
git checkout master || git checkout -b master origin/master | ||
git merge --strategy-option=ours upstream/master | ||
git push -f origin master | ||
- name: Update fork patch | ||
run: | | ||
git checkout patch || git checkout -b patch origin/patch | ||
git rebase --strategy-option=ours upstream/master | ||
git push -f origin patch |