-
Notifications
You must be signed in to change notification settings - Fork 0
39 lines (37 loc) · 1.06 KB
/
CorePressWPTheme.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
name: CorePressWPTheme
on:
schedule:
- cron: '20 9 * * *'
workflow_dispatch:
watch:
types: started
repository_dispatch:
types: sync-CorePressWPTheme
jobs:
repo-sync:
env:
PAT: ${{ secrets.PAT }}
runs-on: ubuntu-latest
if: github.event.repository.owner.id == github.event.sender.id
steps:
- uses: actions/checkout@v2
with:
persist-credentials: false
- name: Create new branch
uses: actions/github-script@v6
with:
script: |
await github.rest.git.createRef({
owner: context.repo.owner,
repo: context.repo.repo,
ref: 'refs/heads/CorePressWPTheme',
sha: context.sha
});
- name: sync CorePressWPTheme
uses: repo-sync/github-sync@v2
if: env.PAT
with:
source_repo: "https://github.com/ghboke/CorePressWPTheme"
source_branch: "main"
destination_branch: "CorePressWPTheme"
github_token: ${{ secrets.PAT }}