Upgrade build-lib version in release pipeline to accomodate new chang… #291
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish Docs to Github Pages | |
on: | |
workflow_dispatch: | |
push: | |
branches: [main] | |
jobs: | |
update-docs: | |
runs-on: ubuntu-latest | |
name: Update gh-pages with docs | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: 18.x | |
- name: Install Tools | |
run: | | |
sudo apt install -y jq | |
npm install -g jsdoc | |
- name: Generate Docs | |
run: | | |
export PACKAGE_VERSION=$(jq .version package.json -r | awk -F. '{print $1"."$2}') | |
export DOC_FOLDER=docs/$PACKAGE_VERSION | |
jsdoc api lib -d $DOC_FOLDER -r --readme README.md | |
cp *.md $DOC_FOLDER | |
cp *.txt $DOC_FOLDER | |
cp OpenSearch.svg $DOC_FOLDER | |
- name: Deploy Docs to gh-pages | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./docs | |
keep_files: true | |
enable_jekyll: true |