1010 workflow_dispatch :
1111 inputs :
1212 ref :
13- description : ' Branch, tag, or commit SHA to deploy (defaults to main)'
13+ description : " Branch, tag, or commit SHA to deploy (defaults to main)"
1414 required : false
15- default : ' main'
15+ default : " main"
1616 type : string
1717
1818# Sets the permissions for the GITHUB_TOKEN to allow deployment to GitHub Pages
@@ -40,14 +40,14 @@ jobs:
4040 ref : ${{ inputs.ref || 'main' }}
4141 # Allow Docusaurus to view the full commit history (required for "last edited at <date> by <person>" functionality)
4242 fetch-depth : 0
43-
43+
4444 - name : Set up Node.js
4545 uses : actions/setup-node@v4
4646 with :
4747 node-version : 20.x
48- cache : ' npm'
49- cache-dependency-path : ' package-lock.json' # root level, since we're using npm workspaces
50-
48+ cache : " npm"
49+ cache-dependency-path : " package-lock.json" # root level, since we're using npm workspaces
50+
5151 - name : Install dependencies
5252 run : npm ci
5353
@@ -61,11 +61,11 @@ jobs:
6161 working-directory : ./packages/docs
6262 run : npm run build
6363 env :
64- # when deploying to a subdirectory of the <org>.github.io domain,
65- # we need to set the BASE_URL to the name of the repo, for a custom
66- # domain this could be /docs/
67- BASE_URL : /blockly/
68-
64+ # When deploying to a subdirectory of your <org|name >.github.io domain, the BASE_URL
65+ # must be set to the name of the repo, go to your repo → Settings → Environments:
66+ # Open the github-pages environment, under Environment variables, add: PAGES_BASE_URL
67+ BASE_URL : ${{ vars.PAGES_BASE_URL || '/docs/' }}
68+
6969 - name : Setup GitHub Pages
7070 uses : actions/configure-pages@v5
7171
0 commit comments