Updates action to sync docs
This commit is contained in:
parent
d02be8ffdd
commit
5887fe8f8f
|
@ -3,31 +3,31 @@
|
||||||
|
|
||||||
name: 🔄 Sync main to Website
|
name: 🔄 Sync main to Website
|
||||||
on:
|
on:
|
||||||
# push:
|
|
||||||
# branches:
|
|
||||||
# - main
|
|
||||||
workflow_dispatch: # Manual dispatch
|
workflow_dispatch: # Manual dispatch
|
||||||
schedule:
|
schedule:
|
||||||
- cron: '0 5 * * 6' # Every Saturday morning.
|
- cron: '0 5 * * 6' # Every Saturday morning.
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
sync-branches:
|
copy-readme:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
name: Syncing branches
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Check out repo
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v3
|
||||||
- name: Set up Node
|
|
||||||
uses: actions/setup-node@v1
|
|
||||||
with:
|
with:
|
||||||
node-version: 12
|
fetch-depth: 0
|
||||||
- name: Opening pull request
|
|
||||||
id: pull
|
- name: Configure git
|
||||||
uses: tretuna/sync-branches@1.4.0
|
run: |
|
||||||
with:
|
git config --global user.email "alicia-gh-bot@mail.as93.net"
|
||||||
GITHUB_TOKEN: ${{ secrets.BOT_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
|
git config --global user.name "Liss-Bot"
|
||||||
FROM_BRANCH: main
|
|
||||||
TO_BRANCH: gh-pages
|
- name: Copy README.md to gh-pages
|
||||||
PULL_REQUEST_TITLE: '[AUTO] Update docs site'
|
run: |
|
||||||
PULL_REQUEST_BODY: |
|
git fetch
|
||||||
Merging main into gh-pages, to be deployed to [awesome-privacy.xyz](https://awesome-privacy.xyz/).
|
git checkout gh-pages
|
||||||
|
git checkout main -- .github/README.md
|
||||||
|
mv .github/README.md README.md
|
||||||
|
git add README.md
|
||||||
|
git commit -m "Update README.md from main"
|
||||||
|
git push origin gh-pages
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue