Skip to content

change the webhook on #7

change the webhook on

change the webhook on #7

Workflow file for this run

name: TSDoc
on:
push:
branches:
- main
jobs:
tsdoc:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v3
with:
node-version: 18
- run: npm install
- run: npm run doc:generate
- name: Configure Git
env:
DEPLOY_PRI: ${{ secrets.DEPLOY_PRI }}
GIT_USERNAME: ${{ github.repository_owner }}
GIT_EMAIL: ${{ github.repository_owner }}@user.github.com
run: |
sudo timedatectl set-timezone "Asia/Shanghai"
mkdir -p ~/.ssh/
echo "$DEPLOY_PRI" > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
ssh-keyscan github.com >> ~/.ssh/known_hosts
git config --global user.name "$GIT_USERNAME"
git config --global user.email "$GIT_EMAIL"
- name: Commit documentation
env:
GIT_URL: "[email protected]:Lhcfl/node-discourse-api.git"
run: |
cd docs
git init
git remote add origin $GIT_URL
git checkout -b docs
git add -A
git commit -m "API Document generated."
- name: Push TSdocs
run: |
cd docs
git push origin HEAD:docs --force