Skip to content

.github/workflows/main.yml #165

.github/workflows/main.yml

.github/workflows/main.yml #165

Workflow file for this run

on:
[create, workflow_dispatch]
permissions:
id-token: write
actions: write
checks: write
contents: write
deployments: write
discussions: write
issues: write
packages: write
pages: write
pull-requests: write
repository-projects: write
security-events: write
statuses: write
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v1
with:
node-version: '16.15.0'
- name: npm install, build and test
run: |
npm install
npm run build
- name: documents
run: npx api-extractor run
continue-on-error: true
- run: npx api-documenter markdown -i ./temp
- uses: actions/checkout@v3
with:
repository: 'heipiao233/dmclc'
path: 'docs'
ref: 'docs'
- run: |
cp ./markdown/* ./docs/ -r
tar cvzf locales.tar.gz locales
cp ./locales.tar.gz ./docs/
cd ./docs/
git config --global user.email "[email protected]"
git config --global user.name "bot"
git add .
git commit -m "auto document and locale"
git push
continue-on-error: true
- name: publish
uses: JS-DevTools/npm-publish@v3
with:
token: ${{ secrets.NPM_TOKEN }}
continue-on-error: true