Skip to content

Commit a94e63f

Browse files
committed
Add support for SOCKET_CLI_NPM_PATH env var
1 parent 92802e1 commit a94e63f

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

src/constants.mts

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ type ENV = Remap<
8080
SOCKET_CLI_GIT_USER_NAME: string
8181
SOCKET_CLI_GITHUB_TOKEN: string
8282
SOCKET_CLI_NO_API_TOKEN: boolean
83+
SOCKET_CLI_NPM_PATH: string
8384
SOCKET_CLI_ORG_SLUG: string
8485
SOCKET_CLI_VIEW_ALL_RISKS: boolean
8586
TERM: string
@@ -341,9 +342,9 @@ const LAZY_ENV = () => {
341342
INLINED_SOCKET_CLI_VERSION_HASH: envAsString(
342343
process.env['INLINED_SOCKET_CLI_VERSION_HASH'],
343344
),
344-
// The location of the %localappdata% folder on Windows used to store user-specific,
345-
// non-roaming application data, like temporary files, cached data, and program
346-
// settings, that are specific to the current machine and user.
345+
// The absolute location of the %localappdata% folder on Windows used to store
346+
// user-specific, non-roaming application data, like temporary files, cached
347+
// data, and program settings, that are specific to the current machine and user.
347348
LOCALAPPDATA: envAsString(env[LOCALAPPDATA]),
348349
// Variable to enable the module compile cache for the Node.js instance.
349350
// https://nodejs.org/api/cli.html#node_compile_cachedir
@@ -416,6 +417,8 @@ const LAZY_ENV = () => {
416417
GITHUB_TOKEN,
417418
// Variable to make the default API token `undefined`.
418419
SOCKET_CLI_NO_API_TOKEN: envAsBoolean(env['SOCKET_CLI_NO_API_TOKEN']),
420+
// The absolute location of the npm bin file.
421+
SOCKET_CLI_NPM_PATH: envAsString(env['SOCKET_CLI_NPM_PATH']),
419422
// Variable to specify the Socket organization slug.
420423
SOCKET_CLI_ORG_SLUG:
421424
envAsString(env['SOCKET_CLI_ORG_SLUG']) ||

0 commit comments

Comments
 (0)