From b9839d7135c88fb04cc3b622a05adb07a089adca Mon Sep 17 00:00:00 2001 From: David Weber Date: Sat, 18 Mar 2023 11:23:11 +0100 Subject: [PATCH] fix: use posix for joining paths Signed-off-by: David Weber --- .changeset/mighty-lamps-cross.md | 5 +++++ packages/cli/src/lib/bundler/config.ts | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 .changeset/mighty-lamps-cross.md diff --git a/.changeset/mighty-lamps-cross.md b/.changeset/mighty-lamps-cross.md new file mode 100644 index 0000000000..6819442105 --- /dev/null +++ b/.changeset/mighty-lamps-cross.md @@ -0,0 +1,5 @@ +--- +'@backstage/cli': patch +--- + +Use `posix` for joining paths instead of platform dependent joins. diff --git a/packages/cli/src/lib/bundler/config.ts b/packages/cli/src/lib/bundler/config.ts index 01f323a082..db98f1486f 100644 --- a/packages/cli/src/lib/bundler/config.ts +++ b/packages/cli/src/lib/bundler/config.ts @@ -15,7 +15,7 @@ */ import fs from 'fs-extra'; -import { resolve as resolvePath, join as joinPath } from 'path'; +import { resolve as resolvePath, posix as posixPath } from 'path'; import ForkTsCheckerWebpackPlugin from 'fork-ts-checker-webpack-plugin'; import HtmlWebpackPlugin from 'html-webpack-plugin'; import ModuleScopePlugin from 'react-dev-utils/ModuleScopePlugin'; @@ -39,6 +39,7 @@ import yn from 'yn'; import { readEntryPoints } from '../monorepo/entryPoints'; import { ExtendedPackage } from '../monorepo'; +const joinPath = posixPath.join; const BUILD_CACHE_ENV_VAR = 'BACKSTAGE_CLI_EXPERIMENTAL_BUILD_CACHE'; export function resolveBaseUrl(config: Config): URL {