generated from alvas-education-foundation/template
-
Notifications
You must be signed in to change notification settings - Fork 0
33 lines (29 loc) · 1.05 KB
/
sync2upstream.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
name: Sync to Upstream
# keep all forked repo synck with original repo
on:
schedule:
- cron: '0 7 * * 1,4'
# scheduled at 07:00 every Monday and Thursday
workflow_dispatch:
jobs:
sync_with_upstream:
runs-on: ubuntu-latest
name: Sync HEAD with upstream latest
steps:
# Step 1: run a standard checkout action, provided by github
- name: Checkout HEAD
uses: actions/checkout@v2
with:
ref: main
# Step 2: run this sync action - specify the upstream repo, upstream branch to sync with, and target sync branch
- name: Pull upstream changes
id: sync
uses: bdougie/Fork-Sync-With-Upstream-action@fork
with:
upstream_repository: alvas-education-foundation/React_dashbord
upstream_branch: main
target_branch: main # optional
github_token: ${{ secrets.GITHUB_TOKEN }} # optional, for accessing repos that requir authentication
# Step 3: Print a helpful timestamp for your records (optional)
- name: Timestamp
run: date