Skip to content

Commit cb7845d

Browse files
authored
Create sync-readme.yml
1 parent 430e22f commit cb7845d

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

.github/workflows/sync-readme.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Sync README.md to index.md
2+
3+
on:
4+
push:
5+
branches: [main]
6+
7+
jobs:
8+
sync:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- name: Checkout repo
12+
uses: actions/checkout@v3
13+
14+
- name: Copy README.md to index.md
15+
run: cp README.md index.md
16+
17+
- name: Commit changes
18+
run: |
19+
git config --global user.name 'github-actions[bot]'
20+
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
21+
git add index.md
22+
git commit -m "Sync README to index.md" || echo "No changes"
23+
git push

0 commit comments

Comments
 (0)