Skip to content

Commit c9a4859

Browse files
committed
ci: update
1 parent ea6c5a7 commit c9a4859

File tree

1 file changed

+12
-14
lines changed

1 file changed

+12
-14
lines changed

.github/workflows/site.yml

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -14,32 +14,30 @@ jobs:
1414
site:
1515
runs-on: ubuntu-latest
1616
steps:
17-
- uses: actions/setup-python@v1
17+
18+
- uses: actions/setup-python@v4
1819
with:
1920
python-version: '3.x'
20-
- uses: actions/checkout@v1
21+
22+
- uses: actions/checkout@v3
23+
2124
- run: python -m pip install recommonmark sphinx sphinx_rtd_theme
25+
2226
- run: |
2327
mv README.md README.ign
2428
make html
2529
mv README.ign README.md
30+
2631
- name: 'publish site to gh-pages'
2732
if: github.event_name != 'pull_request' && github.repository == 'buildthedocs/buildthedocs.github.io'
28-
env:
29-
GH_DEPKEY: ${{ secrets.GHA_DEPLOY_KEY }}
3033
run: |
3134
cd _build/html
35+
git init
36+
cp ../../.git/config ./.git/config
3237
cp ../../README.md ./
3338
touch .nojekyll
34-
git init
3539
git add .
36-
git config --local user.email "push@gha"
37-
git config --local user.name "GHA"
40+
git config --local user.email "BuildTheDocs@GitHubActions"
41+
git config --local user.name "GitHub Actions"
3842
git commit -a -m "update ${{ github.sha }}"
39-
git remote add origin "[email protected]:${{ github.repository }}"
40-
eval `ssh-agent -t 60 -s`
41-
echo "$GH_DEPKEY" | ssh-add -
42-
mkdir -p ~/.ssh/
43-
ssh-keyscan github.com >> ~/.ssh/known_hosts
44-
git push -u origin +HEAD:master
45-
ssh-agent -k
43+
git push -u origin +HEAD:main

0 commit comments

Comments
 (0)