From 07f18644c32949a28e75f4e36fa3ab24f6565ffc Mon Sep 17 00:00:00 2001 From: Olaf Lessenich Date: Wed, 3 Apr 2024 18:31:48 +0200 Subject: [PATCH] Use a path prefix for PR previews Signed-off-by: Olaf Lessenich --- .github/workflows/preview.yml | 2 +- gatsby-config.js | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/preview.yml b/.github/workflows/preview.yml index a5c93ae2..cbc4ac6d 100644 --- a/.github/workflows/preview.yml +++ b/.github/workflows/preview.yml @@ -31,7 +31,7 @@ jobs: - name: Build website run: | npm install - npm run build + PATH_PREFIX="pr-previews/${{ github.event.number }}" npm run build -- --prefix-paths - name: Upload artifact uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 #v4 with: diff --git a/gatsby-config.js b/gatsby-config.js index dd528198..08ca7c15 100644 --- a/gatsby-config.js +++ b/gatsby-config.js @@ -1,4 +1,5 @@ module.exports = { + pathPrefix: process.env.PATH_PREFIX, siteMetadata: { title: 'Theia - Cloud and Desktop IDE Platform', description: "Theia is an open-source cloud   desktop IDE framework implemented in TypeScript."