Skip to content

Commit 782a775

Browse files
author
Travis Holloway
committed
Update website CI to be user agnostic
1 parent a109b73 commit 782a775

1 file changed

Lines changed: 17 additions & 10 deletions

File tree

.github/workflows/website.yml

Lines changed: 17 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ jobs:
1414
build:
1515
if: github.repository == 'cpanel/elevate'
1616
runs-on: ubuntu-latest
17+
permissions:
18+
contents: write
1719
steps:
1820
- name: checkout
1921
uses: actions/checkout@v6
@@ -38,13 +40,18 @@ jobs:
3840
git diff
3941
4042
- name: push
41-
uses: github-actions-x/commit@v2.9
42-
with:
43-
github-token: ${{ secrets.DOCS_DEPLOY_TOKEN }}
44-
push-branch: "docs"
45-
commit-message: "Regenerate Documentation Website"
46-
force-add: "true"
47-
force-push: "true"
48-
files: docs/
49-
name: GitHub Action
50-
email: github.bot@cpanel.net
43+
env:
44+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
45+
run: |
46+
cd docs
47+
git init -q
48+
git checkout -B docs
49+
git -c user.email=github.bot@webpros.com \
50+
-c user.name='GitHub Action' \
51+
add -A
52+
git -c user.email=github.bot@webpros.com \
53+
-c user.name='GitHub Action' \
54+
commit -m 'Regenerate Documentation Website'
55+
git push --force \
56+
"https://x-access-token:${GH_TOKEN}@github.com/${{ github.repository }}" \
57+
docs

0 commit comments

Comments
 (0)