|
13 | 13 |
|
14 | 14 | ## 📚 SHARED STANDARDS |
15 | 15 |
|
16 | | -**See canonical reference:** `../socket-registry/CLAUDE.md` |
| 16 | +**Canonical reference**: `../socket-registry/CLAUDE.md` |
17 | 17 |
|
18 | | -For all shared Socket standards (git workflow, testing, code style, imports, sorting, error handling, cross-platform, CI, etc.), refer to socket-registry/CLAUDE.md. |
| 18 | +All shared standards (git, testing, code style, cross-platform, CI) defined in socket-registry/CLAUDE.md. |
19 | 19 |
|
20 | | -**Git Workflow Reminder**: When user says "commit changes" → create actual commits, use small atomic commits, follow all CLAUDE.md rules: |
21 | | -- Use [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/) style: `<type>(<scope>): <description>` |
22 | | -- NO AI attribution in commit messages |
23 | | - |
24 | | -**Package.json Scripts**: Prefer `pnpm run foo --<flag>` over multiple `foo:bar` scripts (see socket-registry/CLAUDE.md) |
| 20 | +**Quick references**: |
| 21 | +- Commits: [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/) `<type>(<scope>): <description>` - NO AI attribution |
| 22 | +- Scripts: Prefer `pnpm run foo --flag` over `foo:bar` scripts |
25 | 23 |
|
26 | 24 | --- |
27 | 25 |
|
@@ -66,26 +64,38 @@ import colors from 'yoctocolors-cjs' |
66 | 64 | ## 🏗️ LIB-SPECIFIC |
67 | 65 |
|
68 | 66 | ### Architecture |
69 | | -Socket utilities library - Core infrastructure for Socket.dev security tools |
70 | | - |
71 | | -**Core Structure**: |
72 | | -- **Entry**: `src/index.ts` - Main export barrel |
73 | | -- **Constants**: `src/constants/` - Node.js, npm, package manager constants |
74 | | -- **Environment**: `src/env/` - Typed environment variable access |
75 | | -- **Utilities**: `src/lib/` - Core utility functions |
76 | | -- **Types**: `src/types.ts` - TypeScript type definitions |
77 | | -- **External**: `src/external/` - Vendored external dependencies |
78 | | -- **Scripts**: `scripts/` - Build and development scripts |
79 | | - |
80 | | -**Path Aliases**: |
81 | | -- `#constants/*` → `src/constants/*` |
82 | | -- `#env/*` → `src/env/*` |
83 | | -- `#lib/*` → `src/lib/*` |
84 | | -- `#packages/*` → `src/lib/packages/*` |
85 | | -- `#types` → `src/types` |
86 | | -- `#utils/*` → `src/utils/*` |
87 | | - |
88 | | -**Features**: Type-safe utilities, environment variable helpers, file system operations, package management utilities, path normalization, spawn utilities, CLI effects |
| 67 | + |
| 68 | +Core infrastructure library for Socket.dev security tools. |
| 69 | + |
| 70 | +**Directory structure**: |
| 71 | +``` |
| 72 | +src/ |
| 73 | +├── index.ts # Main export barrel |
| 74 | +├── types.ts # TypeScript type definitions |
| 75 | +├── constants/ # Node.js, npm, package manager constants |
| 76 | +├── env/ # Typed environment variable access |
| 77 | +├── lib/ # Core utility functions |
| 78 | +│ └── packages/ # Package management utilities |
| 79 | +├── external/ # Vendored external dependencies |
| 80 | +└── utils/ # Shared utilities |
| 81 | +
|
| 82 | +dist/ # Build output (CommonJS) |
| 83 | +├── external/ # Bundled external dependencies |
| 84 | +└── ... # Compiled source files |
| 85 | +
|
| 86 | +scripts/ # Build and development scripts |
| 87 | +test/ # Test files |
| 88 | +``` |
| 89 | + |
| 90 | +**Path aliases**: |
| 91 | +``` |
| 92 | +#constants/* → src/constants/* |
| 93 | +#env/* → src/env/* |
| 94 | +#lib/* → src/lib/* |
| 95 | +#packages/* → src/lib/packages/* |
| 96 | +#types → src/types |
| 97 | +#utils/* → src/utils/* |
| 98 | +``` |
89 | 99 |
|
90 | 100 | ### Commands |
91 | 101 | - **Build**: `pnpm build` (production build) |
|
0 commit comments