Skip to content

Commit fb1f30e

Browse files
committed
docs(actions): setup push-docs actions to synchronize documentation
1 parent f4d97c6 commit fb1f30e

1 file changed

Lines changed: 37 additions & 0 deletions

File tree

.github/workflows/push-docs.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: synchronize-docs
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
workflow_dispatch:
8+
9+
jobs:
10+
synchronize:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Checkout engine
14+
uses: actions/checkout@v5
15+
with:
16+
path: engine
17+
18+
- name: Checkout docs
19+
uses: actions/checkout@v5
20+
with:
21+
path: docs
22+
repository: nanoforge-dev/docs
23+
token: ${{ secrets.ACTIONS_KEY }}
24+
25+
- name: setup git
26+
run: |
27+
git config --global user.name "github-actions[bot]"
28+
git config --global user.email "username@users.noreply.github.com"
29+
30+
- name: synchronize docs
31+
run: |
32+
mkdir -p docs/engine
33+
cp engine/docs/. -r docs/engine
34+
cd docs
35+
git add .
36+
git commit -m "chore(engine): updating docs"
37+
git push origin main

0 commit comments

Comments
 (0)