We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 63f33bd commit a5786b5Copy full SHA for a5786b5
.github/workflows/publish-docs.yml
@@ -32,8 +32,18 @@ jobs:
32
with:
33
node-version: 20
34
35
+ - name: Calculate BASE_URL
36
+ run: |
37
+ if [[ "${{ github.event.repository.name }}" == "${{ github.repository_owner }}.github.io" ]]; then
38
+ echo "BASE_URL=/pr-preview/pr-${{ github.event.pull_request.number }}/" >> $GITHUB_ENV
39
+ else
40
+ echo "BASE_URL=/${{ github.event.repository.name }}/pr-preview/pr-${{ github.event.pull_request.number }}/" >> $GITHUB_ENV
41
+ fi
42
+
43
- name: Install and Build
44
run: npm ci && npm run build
45
+ env:
46
+ BASE_URL: ${{ env.BASE_URL }}
47
48
- name: Deploy Preview
49
uses: rossjrw/pr-preview-action@v1
0 commit comments