Files
notfiles/.gitea/workflows/sync-readme.yaml
T
alexm 15a19b7a64
Sync README to GitHub / sync (push) Failing after 30s
ci: fix label for runner
2026-07-26 09:22:12 -04:00

37 lines
1009 B
YAML

name: Sync README to GitHub
on:
push:
branches: [main]
paths:
- 'README.md'
- '.gitea/workflows/sync-readme.yaml'
- '.gitea/notice.md'
jobs:
sync:
runs-on: ubuntu-latest
steps:
- name: Check out the Gitea repo
uses: actions/checkout@v4
- name: Build the combined README
run: |
cat README.md > combined.md
printf '\n\n' >> combined.md
cat .gitea/notice.md >> combined.md
- name: Push to the GitHub mirror
env:
GH_TOKEN: ${{ secrets.GH_MIRROR_TOKEN }}
run: |
git clone --depth 1 \
"https://x-access-token:${GH_TOKEN}@github.com/aalexmmaldonado/notfiles.git" ghmirror
cp combined.md ghmirror/README.md
cd ghmirror
git config user.name "Alex Maldonado"
git config user.email "alexm@scient.ing"
git add README.md
git diff --cached --quiet || git commit -m "Sync README from Gitea"
git push