forked from jellyfin/jellyfin-web
-
Notifications
You must be signed in to change notification settings - Fork 0
43 lines (36 loc) · 1.21 KB
/
Sync with Jellyfin Web Repository.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
name: Sync with Jellyfin Web Repository
on:
schedule:
- cron: '0 2 * * *'
workflow_dispatch: # Allows manual triggering of the workflow
jobs:
sync:
runs-on: ubuntu-latest
steps:
- name: Checkout jellyfin-web-requests repo
uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch all history for all branches and tags
token: ${{ secrets.WORKFLOW }}
- name: Configure git
run: |
git config user.name "GitHub Action"
git config user.email "[email protected]"
- name: Add upstream remote
run: git remote add upstream https://github.com/jellyfin/jellyfin-web.git
- name: Fetch changes from upstream
run: git fetch upstream
- name: Merge upstream changes to master
run: |
git checkout master
git merge upstream/master
git push origin master
env:
GITHUB_TOKEN: ${{ secrets.WORKFLOW }}
- name: Discord notification
if: failure()
env:
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
uses: Ilshidur/action-discord@master
with:
args: 'The workflow "Sync with Jellyfin Web Repository" has failed!'