Skip to content

Sync Global Documentation #46

Sync Global Documentation

Sync Global Documentation #46

Workflow file for this run

name: 'Sync Global Documentation'
on:
workflow_dispatch:
schedule:
- cron: '43 21 * * *' # 05:43 AM in Asia/Shanghai (UTC+8)
jobs:
sync:
name: 'Sync'
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: true
- name: Sync submodule
run: |
git submodule update --remote
COMMIT_ID=$(git submodule status global | cut -c2-8)
git config --local user.name "GitHub Actions"
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com"
git commit -am "Sync from mirrorz-org/mirrorz-docs@${COMMIT_ID::7}" && git push || echo "No changes to commit"