File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ import { getNpmBinPath } from '../shadow/npm/paths'
15
15
16
16
import type { Spinner } from '@socketsecurity/registry/lib/spinner'
17
17
18
- const { SOCKET_IPC_HANDSHAKE } = constants
18
+ const { SOCKET_CLI_SENTRY_BUILD , SOCKET_IPC_HANDSHAKE } = constants
19
19
20
20
type SpawnOption = Exclude < Parameters < typeof spawn > [ 2 ] , undefined >
21
21
@@ -51,6 +51,14 @@ export function safeNpmInstall(options?: SafeNpmInstallOptions) {
51
51
...constants . nodeHardenFlags ,
52
52
// Lazily access constants.nodeNoWarningsFlags.
53
53
...constants . nodeNoWarningsFlags ,
54
+ // Lazily access constants.ENV[SOCKET_CLI_SENTRY_BUILD].
55
+ ...( constants . ENV [ SOCKET_CLI_SENTRY_BUILD ]
56
+ ? [
57
+ '--require' ,
58
+ // Lazily access constants.distInstrumentWithSentryPath.
59
+ constants . distInstrumentWithSentryPath
60
+ ]
61
+ : [ ] ) ,
54
62
'--require' ,
55
63
// Lazily access constants.distShadowNpmInjectPath.
56
64
constants . distShadowNpmInjectPath ,
You can’t perform that action at this time.
0 commit comments