From 1c19128e4c0c5c99387407faed71ba6828662f0a Mon Sep 17 00:00:00 2001 From: Dallin Romney Date: Fri, 19 Sep 2025 18:48:30 -0700 Subject: [PATCH] fix: circular import of AUTH_CONFIG_PATH --- extensions/cli/src/auth/authEnv.ts | 4 ++++ extensions/cli/src/auth/workos.ts | 4 +--- 2 files changed, 5 insertions(+), 3 deletions(-) create mode 100644 extensions/cli/src/auth/authEnv.ts diff --git a/extensions/cli/src/auth/authEnv.ts b/extensions/cli/src/auth/authEnv.ts new file mode 100644 index 000000000..1e971f7a2 --- /dev/null +++ b/extensions/cli/src/auth/authEnv.ts @@ -0,0 +1,4 @@ +import * as path from "path"; +import { env } from "../env.js"; + +export const AUTH_CONFIG_PATH = path.join(env.continueHome, "auth.json"); diff --git a/extensions/cli/src/auth/workos.ts b/extensions/cli/src/auth/workos.ts index 9dcadf312..326908d85 100644 --- a/extensions/cli/src/auth/workos.ts +++ b/extensions/cli/src/auth/workos.ts @@ -12,9 +12,6 @@ if (!globalThis.fetch) { globalThis.fetch = nodeFetch as unknown as typeof globalThis.fetch; } -// Config file path -const AUTH_CONFIG_PATH = path.join(env.continueHome, "auth.json"); - // Represents an authenticated user's configuration export interface AuthenticatedConfig { userId: string; @@ -98,6 +95,7 @@ export function getModelName(config: AuthConfig): string | null { } // URI utility functions have been moved to ./uriUtils.ts +import { AUTH_CONFIG_PATH } from "./authEnv.js"; import { autoSelectOrganizationAndConfig } from "./orgSelection.js"; import { pathToUri, slugToUri, uriToPath, uriToSlug } from "./uriUtils.js"; import {