Skip to content

Commit b9674f2

Browse files
committed
refactor(hooks): drop @socketsecurity/ scope from internal hook packages
Internal-only hook packages (path-guard, token-guard, check-new-deps, setup-security-tools, public-surface-reminder) are private:true and never published to npm — the @socketsecurity/ scope was misleading. Renamed to bare hook-<name> across package.json, README.md, and test file references.
1 parent cf895e0 commit b9674f2

6 files changed

Lines changed: 6 additions & 6 deletions

File tree

.claude/hooks/check-new-deps/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"name": "@socketsecurity/hook-check-new-deps",
2+
"name": "@socketsecurityhook-check-new-deps",
33
"private": true,
44
"type": "module",
55
"main": "./index.mts",

.claude/hooks/path-guard/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ Hook bugs fail **open** — a crash in the hook writes a log line and returns ex
5050
## Testing
5151

5252
```bash
53-
pnpm --filter @socketsecurity/hook-path-guard test
53+
pnpm --filter @socketsecurityhook-path-guard test
5454
```
5555

5656
Adding a new detection pattern: update `STAGE_SEGMENTS` (or `KNOWN_SIBLING_PACKAGES`) in `index.mts`, add a positive and negative test in `test/path-guard.test.mts`.

.claude/hooks/path-guard/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"name": "@socketsecurity/hook-path-guard",
2+
"name": "@socketsecurityhook-path-guard",
33
"private": true,
44
"type": "module",
55
"main": "./index.mts",

.claude/hooks/path-guard/test/path-guard.test.mts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// mock PreToolUse payload to the hook's stdin and asserts on its exit
33
// code + stderr. Exit 2 = blocked; exit 0 = allowed.
44
//
5-
// Run: pnpm --filter @socketsecurity/hook-path-guard test
5+
// Run: pnpm --filter @socketsecurityhook-path-guard test
66
// (or directly: node --test test/*.test.mts)
77

88
import { spawnSync } from 'node:child_process'

.claude/hooks/token-guard/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ The hook reads the tool-use payload from stdin, type-checks `tool_name === 'Bash
4141
## Testing
4242

4343
```bash
44-
pnpm --filter @socketsecurity/hook-token-guard test
44+
pnpm --filter @socketsecurityhook-token-guard test
4545
```
4646

4747
Adding new token-shape detections: update `LITERAL_TOKEN_PATTERNS` in `index.mts`, add a positive and negative test in `test/token-guard.test.mts`.

.claude/hooks/token-guard/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"name": "@socketsecurity/hook-token-guard",
2+
"name": "@socketsecurityhook-token-guard",
33
"private": true,
44
"type": "module",
55
"main": "./index.mts",

0 commit comments

Comments
 (0)