-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: provide manual deployment of TypeDoc
- Loading branch information
1 parent
85f7bf1
commit 4ac57c1
Showing
2 changed files
with
52 additions
and
4 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
name: Publish TypeDoc | ||
on: workflow_dispatch | ||
env: | ||
NODE_VERSION: 20.14.0 | ||
jobs: | ||
install: | ||
name: 'Installing NPM modules' | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: ${{ env.NODE_VERSION }} | ||
- name: 'Caching NPM modules if necessary' | ||
uses: actions/cache@v4 | ||
id: node-modules-cache | ||
with: | ||
path: ./node_modules | ||
key: node_modules-${{ runner.os }}-${{ hashFiles('**/package-lock.json') }} | ||
- if: steps.node-modules-cache.outputs.cache-hit != 'true' | ||
run: npm ci | ||
publish-documentation: | ||
name: 'Publishing TypeDoc' | ||
needs: install | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: ${{ env.NODE_VERSION }} | ||
- name: 'Restoring NPM modules from cache' | ||
uses: actions/cache@v4 | ||
with: | ||
path: ./node_modules | ||
key: node_modules-${{ runner.os }}-${{ hashFiles('**/package-lock.json') }} | ||
- name: 'Building TypeDoc' | ||
run: npm run microfrontend-platform:typedoc | ||
- name: 'Publishing TypeDoc to Vercel' | ||
uses: SchweizerischeBundesbahnen/scion-toolkit/.github/actions/vercel-deploy@master | ||
with: | ||
dist-folder: dist/microfrontend-platform-api | ||
vercel-token: ${{ secrets.VERCEL_TOKEN }} | ||
org-id: ${{ secrets.VERCEL_ORG_ID }} | ||
project-id: ${{ secrets.VERCEL_MICROFRONTEND_PLATFORM_API_PROJECT_ID }} | ||
version: ${{ needs.build-platform.outputs.version }} | ||
aliases: | | ||
microfrontend-platform-api.scion.vercel.app, | ||
microfrontend-platform-api-v%v.scion.vercel.app |