Skip to content

Commit 9233acb

Browse files
committed
Update constants for build optimization
1 parent 464a906 commit 9233acb

3 files changed

Lines changed: 12 additions & 3 deletions

File tree

registry/src/lib/constants/ENV.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,10 @@ export default ObjectFreeze({
6767
// PRE_COMMIT is set to '1' by our 'test-pre-commit' script run by the
6868
// .husky/pre-commit hook.
6969
PRE_COMMIT: envAsBoolean(env['PRE_COMMIT']),
70-
// Enable debug logging in Socket CLI.
71-
SOCKET_CLI_DEBUG: !!DEBUG || envAsBoolean(env['SOCKET_CLI_DEBUG']),
70+
// Override the default Socket cacache directory (~/.socket/_cacache).
71+
SOCKET_CACACHE_DIR: envAsString(env['SOCKET_CACACHE_DIR']),
72+
// Enable debug logging in Socket tools.
73+
SOCKET_DEBUG: !!DEBUG || envAsBoolean(env['SOCKET_DEBUG']),
7274
// Temporary directory path. TMPDIR (POSIX), TEMP (Windows), or TMP (fallback).
7375
TMPDIR,
7476
// Enable verbose build output.

registry/src/lib/constants/index.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,13 @@ const props: Record<string, any> = {
1515
BUN_LOCKB: 'bun.lockb',
1616
bunCachePath: undefined,
1717
CACHE_DIR: 'cache',
18+
CHAR_BACKWARD_SLASH: 92,
19+
CHAR_COLON: 58,
20+
CHAR_FORWARD_SLASH: 47,
21+
CHAR_LOWERCASE_A: 97,
22+
CHAR_LOWERCASE_Z: 122,
23+
CHAR_UPPERCASE_A: 65,
24+
CHAR_UPPERCASE_Z: 90,
1825
CACHE_GITHUB_DIR: 'github',
1926
CACHE_SOCKET_API_DIR: 'socket-api',
2027
CACHE_TTL_DIR: 'ttl',

registry/src/lib/constants/node-debug-flags.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,5 @@ import ENV from './ENV'
77
const ObjectFreeze = Object.freeze
88

99
export default ObjectFreeze(
10-
ENV.SOCKET_CLI_DEBUG ? ['--trace-uncaught', '--trace-warnings'] : [],
10+
ENV.SOCKET_DEBUG ? ['--trace-uncaught', '--trace-warnings'] : [],
1111
)

0 commit comments

Comments
 (0)