Skip to content

Commit

Permalink
switch to GH Pages WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
newcat committed Oct 23, 2024
1 parent 9a06288 commit 2f6d0ec
Showing 1 changed file with 10 additions and 21 deletions.
31 changes: 10 additions & 21 deletions .github/workflows/manual-docs-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ name: Manual Docs Publish
permissions:
id-token: write
contents: write
pages: write

on: workflow_dispatch

Expand All @@ -13,10 +14,10 @@ jobs:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Use Node.js 20
uses: actions/setup-node@v3
- name: Use Node.js 22
uses: actions/setup-node@v4
with:
node-version: "20"
node-version: "22"
- name: Setup Yarn v3
run: |
corepack enable
Expand All @@ -29,22 +30,10 @@ jobs:
run: |
yarn run generate-api-docs
yarn run docs:build
- name: Azure login
uses: azure/login@v1
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
client-id: ${{ secrets.AZURE_CLIENT_ID }}
tenant-id: ${{ secrets.AZURE_TENANT_ID }}
subscription-id: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
- name: Publish docs
uses: azure/CLI@v1
with:
inlineScript: |
az storage blob sync --account-name baklavajs -c '$web' -s "./docs/.vitepress/dist/"
- name: Purge CDN endpoint
uses: azure/CLI@v1
with:
inlineScript: |
az afd endpoint purge --content-paths "/*" --profile-name "baklavajs" --endpoint-name "baklavajs" --resource-group "Private" --no-wait
- name: Azure Logout
run: az logout
if: always()
path: "./docs/.vitepress/dist/"
- name: Deploy
id: deployment
uses: actions/deploy-pages@v4

0 comments on commit 2f6d0ec

Please sign in to comment.