Synchronizing branch "wiki" with GitHub Wiki #169
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
name: Synchronizing branch "wiki" with GitHub Wiki | |
on: | |
[gollum, workflow_dispatch] | |
jobs: | |
sync-with-wiki: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
repository: ${{ format('{0}.wiki', github.repository) }} | |
persist-credentials: false | |
fetch-depth: 0 | |
- name: sync | |
run: | | |
git remote add main-repo "${GITHUB_SERVER_URL%%://*}://${PAT_USERNAME}:${PAT_TOKEN}@${GITHUB_SERVER_URL#*://}/$GITHUB_REPOSITORY.git" | |
git push main-repo @:wiki | |
env: | |
PAT_USERNAME: ${{ secrets.PAT_USERNAME }} | |
PAT_TOKEN: ${{ secrets.PAT_TOKEN }} |