Skip to content

Commit 58f3fb0

Browse files
Test deployment
1 parent c4d5727 commit 58f3fb0

File tree

2 files changed

+18
-4
lines changed

2 files changed

+18
-4
lines changed

.github/workflows/main.yml

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ jobs:
6666
uses: actions/checkout@v4
6767
with:
6868
ref: gh-pages
69+
path: neoteroi
6970

7071
- name: Download artifact
7172
uses: actions/download-artifact@v4
@@ -79,7 +80,20 @@ jobs:
7980
8081
- name: Deploy to gh-pages branch
8182
run: |
82-
# git config user.name "${GITHUB_ACTOR}"
83-
# git config user.email "${GITHUB_ACTOR}@users.noreply.github.com"
84-
8583
tree
84+
85+
find neoteroi -mindepth 1 ! -name '.git' ! -name 'CNAME' ! -name 'README.md' ! -path 'neoteroi/.git/*' -exec rm -rf {} +
86+
cp -r site/* neoteroi/
87+
rm -rf site
88+
89+
cd neoteroi
90+
git config user.name "${GITHUB_ACTOR}"
91+
git config user.email "${GITHUB_ACTOR}@users.noreply.github.com"
92+
93+
git add .
94+
git commit -m "Deploy documentation on $(date -u '+%Y-%m-%d %H:%M:%S UTC')"
95+
96+
git checkout -b test
97+
git push origin test --force
98+
99+
echo "Published to test"

deploy.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ if [[ "$confirmation" =~ ^[Yy]$ ]]; then
2020
cp copy/CNAME ../site/
2121
cp copy/README.md ../site/
2222

23-
rm -rf copy/*
23+
find copy -mindepth 1 ! -name '.git' ! -name 'CNAME' ! -name 'README.md' ! -path 'copy/.git/*' -exec rm -rf {} +
2424
cp -r ../site/* copy/
2525

2626
cd copy/

0 commit comments

Comments
 (0)