pi-agent-toolkit 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/dotfiles/AGENTS.md +197 -0
- package/dist/dotfiles/APPEND_SYSTEM.md +78 -0
- package/dist/dotfiles/agent-modes.json +12 -0
- package/dist/dotfiles/agent-skills/exa-search/.env.example +4 -0
- package/dist/dotfiles/agent-skills/exa-search/SKILL.md +234 -0
- package/dist/dotfiles/agent-skills/exa-search/scripts/exa-api.cjs +197 -0
- package/dist/dotfiles/auth.json.template +5 -0
- package/dist/dotfiles/damage-control-rules.yaml +318 -0
- package/dist/dotfiles/extensions/btw.ts +1031 -0
- package/dist/dotfiles/extensions/commit-approval.ts +590 -0
- package/dist/dotfiles/extensions/context.ts +578 -0
- package/dist/dotfiles/extensions/control.ts +1748 -0
- package/dist/dotfiles/extensions/damage-control/index.ts +543 -0
- package/dist/dotfiles/extensions/damage-control/node_modules/.package-lock.json +22 -0
- package/dist/dotfiles/extensions/damage-control/package-lock.json +28 -0
- package/dist/dotfiles/extensions/damage-control/package.json +7 -0
- package/dist/dotfiles/extensions/dirty-repo-guard.ts +56 -0
- package/dist/dotfiles/extensions/exa-enforce.ts +51 -0
- package/dist/dotfiles/extensions/exa-search-tool.ts +384 -0
- package/dist/dotfiles/extensions/execute-command/index.ts +82 -0
- package/dist/dotfiles/extensions/files.ts +1112 -0
- package/dist/dotfiles/extensions/loop.ts +446 -0
- package/dist/dotfiles/extensions/pr-approval.ts +730 -0
- package/dist/dotfiles/extensions/qna-interactive.ts +532 -0
- package/dist/dotfiles/extensions/question-mode.ts +242 -0
- package/dist/dotfiles/extensions/require-session-name-on-exit.ts +141 -0
- package/dist/dotfiles/extensions/review.ts +2091 -0
- package/dist/dotfiles/extensions/session-breakdown.ts +1629 -0
- package/dist/dotfiles/extensions/term-notify.ts +150 -0
- package/dist/dotfiles/extensions/tilldone.ts +527 -0
- package/dist/dotfiles/extensions/todos.ts +2082 -0
- package/dist/dotfiles/extensions/tools.ts +146 -0
- package/dist/dotfiles/extensions/uv.ts +123 -0
- package/dist/dotfiles/global-skills/brainstorm/SKILL.md +10 -0
- package/dist/dotfiles/global-skills/cli-detector/SKILL.md +192 -0
- package/dist/dotfiles/global-skills/gh-issue-creator/SKILL.md +173 -0
- package/dist/dotfiles/global-skills/google-chat-cards-v2/SKILL.md +237 -0
- package/dist/dotfiles/global-skills/google-chat-cards-v2/references/bridge_tap_implementation.md +466 -0
- package/dist/dotfiles/global-skills/technical-docs/SKILL.md +204 -0
- package/dist/dotfiles/global-skills/technical-docs/references/diagrams.md +168 -0
- package/dist/dotfiles/global-skills/technical-docs/references/examples.md +449 -0
- package/dist/dotfiles/global-skills/technical-docs/scripts/validate_docs.py +352 -0
- package/dist/dotfiles/global-skills/whats-new/SKILL.md +159 -0
- package/dist/dotfiles/intercepted-commands/pip +7 -0
- package/dist/dotfiles/intercepted-commands/pip3 +7 -0
- package/dist/dotfiles/intercepted-commands/poetry +10 -0
- package/dist/dotfiles/intercepted-commands/python +104 -0
- package/dist/dotfiles/intercepted-commands/python3 +104 -0
- package/dist/dotfiles/mcp.json.template +32 -0
- package/dist/dotfiles/models.json +27 -0
- package/dist/dotfiles/settings.json +25 -0
- package/dist/index.js +1344 -0
- package/package.json +34 -0
|
@@ -0,0 +1,197 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Exa API Helper Script
|
|
5
|
+
* Provides a CLI wrapper around Exa endpoints for Pi skill integration.
|
|
6
|
+
*
|
|
7
|
+
* Usage:
|
|
8
|
+
* node exa-api.cjs <search|contents|findsimilar|answer|research> [<json-string>]
|
|
9
|
+
* cat payload.json | node exa-api.cjs search
|
|
10
|
+
* node exa-api.cjs search --file ./payload.json
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
const https = require('https');
|
|
14
|
+
const fs = require('fs');
|
|
15
|
+
const path = require('path');
|
|
16
|
+
|
|
17
|
+
const API_BASE = 'https://api.exa.ai';
|
|
18
|
+
|
|
19
|
+
function readApiKeyFromFile(filePath) {
|
|
20
|
+
if (!fs.existsSync(filePath)) {
|
|
21
|
+
return null;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
const envContent = fs.readFileSync(filePath, 'utf8');
|
|
25
|
+
const match = envContent.match(/EXA_API_KEY\s*=\s*(.+)/);
|
|
26
|
+
if (!match) {
|
|
27
|
+
return null;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
return match[1].trim().replace(/^["']|["']$/g, '');
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
function loadApiKey() {
|
|
34
|
+
if (process.env.EXA_API_KEY) {
|
|
35
|
+
return process.env.EXA_API_KEY;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
const candidatePaths = [
|
|
39
|
+
path.join(__dirname, '..', '.env'),
|
|
40
|
+
path.join(__dirname, '.env'),
|
|
41
|
+
];
|
|
42
|
+
|
|
43
|
+
for (const envPath of candidatePaths) {
|
|
44
|
+
const apiKey = readApiKeyFromFile(envPath);
|
|
45
|
+
if (apiKey) return apiKey;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
return null;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
function usage() {
|
|
52
|
+
const cmd = path.basename(process.argv[1] || 'exa-api.cjs');
|
|
53
|
+
console.error(
|
|
54
|
+
[
|
|
55
|
+
'Usage:',
|
|
56
|
+
` node ${cmd} <search|contents|findsimilar|answer|research> [<json-string>]`,
|
|
57
|
+
` cat payload.json | node ${cmd} search`,
|
|
58
|
+
` node ${cmd} search --file ./payload.json`,
|
|
59
|
+
'',
|
|
60
|
+
'Env:',
|
|
61
|
+
' EXA_API_KEY (env var), .env in the skill root, or .env next to this script',
|
|
62
|
+
].join('\n'),
|
|
63
|
+
);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
function readStdin() {
|
|
67
|
+
return new Promise((resolve, reject) => {
|
|
68
|
+
let data = '';
|
|
69
|
+
process.stdin.setEncoding('utf8');
|
|
70
|
+
process.stdin.on('data', (chunk) => {
|
|
71
|
+
data += chunk;
|
|
72
|
+
});
|
|
73
|
+
process.stdin.on('end', () => resolve(data));
|
|
74
|
+
process.stdin.on('error', reject);
|
|
75
|
+
});
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
async function readPayload(args) {
|
|
79
|
+
const fileFlagIndex = args.findIndex((arg) => arg === '--file');
|
|
80
|
+
if (fileFlagIndex !== -1) {
|
|
81
|
+
const filePath = args[fileFlagIndex + 1];
|
|
82
|
+
if (!filePath) {
|
|
83
|
+
throw new Error('Missing value for --file');
|
|
84
|
+
}
|
|
85
|
+
const content = fs.readFileSync(filePath, 'utf8');
|
|
86
|
+
return JSON.parse(content);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
const dataFlagIndex = args.findIndex((arg) => arg === '--data');
|
|
90
|
+
if (dataFlagIndex !== -1) {
|
|
91
|
+
const json = args[dataFlagIndex + 1];
|
|
92
|
+
if (!json) {
|
|
93
|
+
throw new Error('Missing value for --data');
|
|
94
|
+
}
|
|
95
|
+
return JSON.parse(json);
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
if (args[0] && !args[0].startsWith('-')) {
|
|
99
|
+
return JSON.parse(args[0]);
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
if (process.stdin.isTTY) {
|
|
103
|
+
throw new Error('No payload provided (pass JSON arg, --data, --file, or pipe via stdin)');
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
const stdin = await readStdin();
|
|
107
|
+
if (!stdin.trim()) {
|
|
108
|
+
throw new Error('Empty stdin payload');
|
|
109
|
+
}
|
|
110
|
+
return JSON.parse(stdin);
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
function postJson(endpointPath, apiKey, payload) {
|
|
114
|
+
return new Promise((resolve, reject) => {
|
|
115
|
+
const body = JSON.stringify(payload);
|
|
116
|
+
const url = new URL(endpointPath, API_BASE);
|
|
117
|
+
|
|
118
|
+
const req = https.request(
|
|
119
|
+
url,
|
|
120
|
+
{
|
|
121
|
+
method: 'POST',
|
|
122
|
+
headers: {
|
|
123
|
+
'x-api-key': apiKey,
|
|
124
|
+
'Content-Type': 'application/json',
|
|
125
|
+
'Content-Length': Buffer.byteLength(body),
|
|
126
|
+
'User-Agent': 'Exa-Skill/1.0',
|
|
127
|
+
},
|
|
128
|
+
timeout: 60_000,
|
|
129
|
+
},
|
|
130
|
+
(res) => {
|
|
131
|
+
let data = '';
|
|
132
|
+
res.setEncoding('utf8');
|
|
133
|
+
res.on('data', (chunk) => {
|
|
134
|
+
data += chunk;
|
|
135
|
+
});
|
|
136
|
+
res.on('end', () => {
|
|
137
|
+
const ok = res.statusCode && res.statusCode >= 200 && res.statusCode < 300;
|
|
138
|
+
if (!ok) {
|
|
139
|
+
reject(new Error(`API Error ${res.statusCode}: ${data}`));
|
|
140
|
+
return;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
try {
|
|
144
|
+
resolve(JSON.parse(data));
|
|
145
|
+
} catch {
|
|
146
|
+
resolve(data);
|
|
147
|
+
}
|
|
148
|
+
});
|
|
149
|
+
},
|
|
150
|
+
);
|
|
151
|
+
|
|
152
|
+
req.on('error', reject);
|
|
153
|
+
req.on('timeout', () => {
|
|
154
|
+
req.destroy(new Error('Request timed out'));
|
|
155
|
+
});
|
|
156
|
+
|
|
157
|
+
req.write(body);
|
|
158
|
+
req.end();
|
|
159
|
+
});
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
const ENDPOINT_BY_COMMAND = {
|
|
163
|
+
search: '/search',
|
|
164
|
+
contents: '/contents',
|
|
165
|
+
findsimilar: '/findSimilar',
|
|
166
|
+
answer: '/answer',
|
|
167
|
+
research: '/research',
|
|
168
|
+
};
|
|
169
|
+
|
|
170
|
+
(async () => {
|
|
171
|
+
const command = process.argv[2];
|
|
172
|
+
if (!command || command === '--help' || command === '-h') {
|
|
173
|
+
usage();
|
|
174
|
+
process.exit(command ? 0 : 1);
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
const endpoint = ENDPOINT_BY_COMMAND[command];
|
|
178
|
+
if (!endpoint) {
|
|
179
|
+
usage();
|
|
180
|
+
process.exit(1);
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
const apiKey = loadApiKey();
|
|
184
|
+
if (!apiKey) {
|
|
185
|
+
console.error('Missing Exa API key: set EXA_API_KEY or create .env in the skill root');
|
|
186
|
+
process.exit(1);
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
try {
|
|
190
|
+
const payload = await readPayload(process.argv.slice(3));
|
|
191
|
+
const result = await postJson(endpoint, apiKey, payload);
|
|
192
|
+
console.log(JSON.stringify(result, null, 2));
|
|
193
|
+
} catch (error) {
|
|
194
|
+
console.error(`Error: ${error.message}`);
|
|
195
|
+
process.exit(1);
|
|
196
|
+
}
|
|
197
|
+
})();
|
|
@@ -0,0 +1,318 @@
|
|
|
1
|
+
# Damage Control Rules
|
|
2
|
+
#
|
|
3
|
+
# Defines safety guardrails for the PI agent. Loaded by damage-control.ts.
|
|
4
|
+
#
|
|
5
|
+
# Sections:
|
|
6
|
+
# bashToolPatterns - regex patterns matched against bash commands
|
|
7
|
+
# "ask: true" prompts for confirmation instead of hard-blocking
|
|
8
|
+
# zeroAccessPaths - agent cannot read, search, or modify these paths
|
|
9
|
+
# askAccessPaths - agent must ask before reading or searching these paths
|
|
10
|
+
# readOnlyPaths - agent can read but not write or delete
|
|
11
|
+
# noDeletePaths - agent can read and write but not delete
|
|
12
|
+
#
|
|
13
|
+
# Path entries support:
|
|
14
|
+
# - Globs: *.pem, *-credentials.json
|
|
15
|
+
# - Home dir: ~/
|
|
16
|
+
# - Directories (trailing /): ~/.ssh/
|
|
17
|
+
|
|
18
|
+
bashToolPatterns:
|
|
19
|
+
# -- Destructive file operations --
|
|
20
|
+
- pattern: '\brm\b'
|
|
21
|
+
reason: rm usage (delete operation)
|
|
22
|
+
ask: true
|
|
23
|
+
- pattern: '\bgit\s+rm\b'
|
|
24
|
+
reason: git rm (delete operation)
|
|
25
|
+
ask: true
|
|
26
|
+
- pattern: '\bfind\b[^\n]*\s-delete\b'
|
|
27
|
+
reason: find with -delete flag
|
|
28
|
+
ask: true
|
|
29
|
+
- pattern: '\bsudo\b'
|
|
30
|
+
reason: sudo (elevated privileges)
|
|
31
|
+
ask: true
|
|
32
|
+
- pattern: '\brm\s+(-[^\s]*)*-[rRf]'
|
|
33
|
+
reason: rm with recursive or force flags
|
|
34
|
+
- pattern: '\brm\s+-[rRf]'
|
|
35
|
+
reason: rm with recursive or force flags
|
|
36
|
+
- pattern: '\brm\s+--recursive'
|
|
37
|
+
reason: rm with --recursive flag
|
|
38
|
+
- pattern: '\brm\s+--force'
|
|
39
|
+
reason: rm with --force flag
|
|
40
|
+
- pattern: '\bsudo\s+rm\b'
|
|
41
|
+
reason: sudo rm (blocked, not just asked)
|
|
42
|
+
- pattern: '\brmdir\s+--ignore-fail-on-non-empty'
|
|
43
|
+
reason: rmdir ignore-fail
|
|
44
|
+
- pattern: '\bchmod\s+(-[^\s]+\s+)*777\b'
|
|
45
|
+
reason: chmod 777 (world writable)
|
|
46
|
+
- pattern: '\bchmod\s+-[Rr].*777'
|
|
47
|
+
reason: recursive chmod 777
|
|
48
|
+
- pattern: '\bchown\s+-[Rr].*\broot\b'
|
|
49
|
+
reason: recursive chown to root
|
|
50
|
+
- pattern: '\bmkfs\.'
|
|
51
|
+
reason: filesystem format command
|
|
52
|
+
- pattern: '\bdd\s+.*of=/dev/'
|
|
53
|
+
reason: dd writing to device
|
|
54
|
+
- pattern: '\bkill\s+-9\s+-1\b'
|
|
55
|
+
reason: kill all processes
|
|
56
|
+
- pattern: '\bkillall\s+-9\b'
|
|
57
|
+
reason: killall -9
|
|
58
|
+
- pattern: '\bpkill\s+-9\b'
|
|
59
|
+
reason: pkill -9
|
|
60
|
+
- pattern: '\bhistory\s+-c\b'
|
|
61
|
+
reason: clearing shell history
|
|
62
|
+
|
|
63
|
+
# -- Git --
|
|
64
|
+
- pattern: '\bgit\s+reset\s+--hard\b'
|
|
65
|
+
reason: git reset --hard (use --soft or stash)
|
|
66
|
+
- pattern: '\bgit\s+clean\s+(-[^\s]*)*-[fd]'
|
|
67
|
+
reason: git clean with force/directory flags
|
|
68
|
+
- pattern: '\bgit\s+push\s+.*--force(?!-with-lease)'
|
|
69
|
+
reason: git push --force (use --force-with-lease)
|
|
70
|
+
- pattern: '\bgit\s+push\s+(-[^\s]*)*-f\b'
|
|
71
|
+
reason: git push -f (use --force-with-lease)
|
|
72
|
+
- pattern: '\bgit\s+stash\s+clear\b'
|
|
73
|
+
reason: git stash clear (deletes ALL stashes)
|
|
74
|
+
- pattern: '\bgit\s+reflog\s+expire\b'
|
|
75
|
+
reason: git reflog expire (destroys recovery mechanism)
|
|
76
|
+
- pattern: '\bgit\s+gc\s+.*--prune=now'
|
|
77
|
+
reason: git gc --prune=now (can lose dangling commits)
|
|
78
|
+
- pattern: '\bgit\s+filter-branch\b'
|
|
79
|
+
reason: git filter-branch (rewrites entire history)
|
|
80
|
+
- pattern: '\bgit\b.*--no-verify'
|
|
81
|
+
reason: git --no-verify bypasses all hooks
|
|
82
|
+
- pattern: '\bgit\s+checkout\s+--\s*\.'
|
|
83
|
+
reason: discards all uncommitted changes
|
|
84
|
+
ask: true
|
|
85
|
+
- pattern: '\bgit\s+restore\s+\.'
|
|
86
|
+
reason: discards all uncommitted changes
|
|
87
|
+
ask: true
|
|
88
|
+
- pattern: '\bgit\s+stash\s+drop\b'
|
|
89
|
+
reason: permanently deletes a stash
|
|
90
|
+
ask: true
|
|
91
|
+
- pattern: '\bgit\s+branch\s+(-[^\s]*)*-D'
|
|
92
|
+
reason: force deletes branch (even if unmerged)
|
|
93
|
+
ask: true
|
|
94
|
+
- pattern: '\bgit\s+push\s+\S+\s+--delete\b'
|
|
95
|
+
reason: deletes remote branch
|
|
96
|
+
ask: true
|
|
97
|
+
- pattern: '\bgit\s+push\s+\S+\s+:\S+'
|
|
98
|
+
reason: deletes remote branch (old syntax)
|
|
99
|
+
ask: true
|
|
100
|
+
|
|
101
|
+
# -- AWS S3 allowlist --
|
|
102
|
+
# Allow rules are checked first and always win over block rules.
|
|
103
|
+
# Only ls (list) and cp (copy/download/upload) are permitted.
|
|
104
|
+
- pattern: '\baws\s+s3\s+(ls|cp)\b'
|
|
105
|
+
reason: aws S3 ls/cp operations are permitted
|
|
106
|
+
allow: true
|
|
107
|
+
|
|
108
|
+
# -- AWS S3 blocks --
|
|
109
|
+
- pattern: '\baws\s+s3\s+rm\b'
|
|
110
|
+
reason: aws s3 rm (deletes S3 objects)
|
|
111
|
+
- pattern: '\baws\s+s3\s+rb\b'
|
|
112
|
+
reason: aws s3 rb (removes bucket)
|
|
113
|
+
- pattern: '\baws\s+s3\s+mv\b'
|
|
114
|
+
reason: aws s3 mv (moves by deleting source objects)
|
|
115
|
+
- pattern: '\baws\s+s3\s+sync\b.*\s--delete\b'
|
|
116
|
+
reason: aws s3 sync --delete (removes destination objects)
|
|
117
|
+
- pattern: '\baws\s+s3\s+sync\b'
|
|
118
|
+
reason: aws s3 sync is blocked; use only explicit find/read/download/upload flows
|
|
119
|
+
- pattern: '\baws\s+s3api\s+(?:delete|remove)\S*\b'
|
|
120
|
+
reason: aws s3api delete/remove operation
|
|
121
|
+
- pattern: '\baws\s+s3api\s+abort-multipart-upload\b'
|
|
122
|
+
reason: aws s3api abort-multipart-upload (discards multipart upload)
|
|
123
|
+
- pattern: '\baws\s+s3api\b.*\b--delete\b'
|
|
124
|
+
reason: aws s3api command with --delete flag
|
|
125
|
+
- pattern: '\baws\s+s3control\s+(?:delete|remove)\S*\b'
|
|
126
|
+
reason: aws s3control delete/remove operation
|
|
127
|
+
- pattern: '\baws\s+s3control\b.*\b--delete\b'
|
|
128
|
+
reason: aws s3control command with --delete flag
|
|
129
|
+
- pattern: '\baws\s+s3api\s+(?:put|create|copy)\S*\b'
|
|
130
|
+
reason: aws s3api mutating command is blocked; allow only cp uploads/downloads
|
|
131
|
+
- pattern: '\baws\s+s3control\s+(?:put|create|update)\S*\b'
|
|
132
|
+
reason: aws s3control mutating command is blocked
|
|
133
|
+
- pattern: '\baws\s+s3\s+presign\b'
|
|
134
|
+
reason: aws s3 presign is blocked
|
|
135
|
+
- pattern: '\baws\s+s3\b'
|
|
136
|
+
reason: aws S3 command not in allowlist (only ls/cp are permitted via allow rules)
|
|
137
|
+
- pattern: '\baws\s+ec2\s+terminate-instances\b'
|
|
138
|
+
reason: aws ec2 terminate-instances
|
|
139
|
+
- pattern: '\baws\s+rds\s+delete-db-instance\b'
|
|
140
|
+
reason: aws rds delete-db-instance
|
|
141
|
+
- pattern: '\baws\s+cloudformation\s+delete-stack\b'
|
|
142
|
+
reason: aws cloudformation delete-stack
|
|
143
|
+
- pattern: '\baws\s+dynamodb\s+delete-table\b'
|
|
144
|
+
reason: aws dynamodb delete-table
|
|
145
|
+
- pattern: '\baws\s+eks\s+delete-cluster\b'
|
|
146
|
+
reason: aws eks delete-cluster
|
|
147
|
+
- pattern: '\baws\s+lambda\s+delete-function\b'
|
|
148
|
+
reason: aws lambda delete-function
|
|
149
|
+
- pattern: '\baws\s+iam\s+delete-role\b'
|
|
150
|
+
reason: aws iam delete-role
|
|
151
|
+
- pattern: '\baws\s+iam\s+delete-user\b'
|
|
152
|
+
reason: aws iam delete-user
|
|
153
|
+
|
|
154
|
+
# -- GCP --
|
|
155
|
+
- pattern: '\bgcloud\s+projects\s+delete\b'
|
|
156
|
+
reason: gcloud projects delete (DELETES ENTIRE PROJECT)
|
|
157
|
+
- pattern: '\bgcloud\s+compute\s+instances\s+delete\b'
|
|
158
|
+
reason: gcloud compute instances delete
|
|
159
|
+
- pattern: '\bgcloud\s+sql\s+instances\s+delete\b'
|
|
160
|
+
reason: gcloud sql instances delete
|
|
161
|
+
- pattern: '\bgcloud\s+container\s+clusters\s+delete\b'
|
|
162
|
+
reason: gcloud container clusters delete (GKE)
|
|
163
|
+
- pattern: '\bgcloud\s+storage\s+rm\s+.*-r'
|
|
164
|
+
reason: gcloud storage rm -r (recursive delete)
|
|
165
|
+
- pattern: '\bgcloud\s+functions\s+delete\b'
|
|
166
|
+
reason: gcloud functions delete
|
|
167
|
+
- pattern: '\bgcloud\s+iam\s+service-accounts\s+delete\b'
|
|
168
|
+
reason: gcloud iam service-accounts delete
|
|
169
|
+
- pattern: '\bgcloud\s+run\s+services\s+delete\b'
|
|
170
|
+
reason: gcloud run services delete
|
|
171
|
+
- pattern: '\bgcloud\s+run\s+jobs\s+delete\b'
|
|
172
|
+
reason: gcloud run jobs delete
|
|
173
|
+
- pattern: '\bgcloud\s+services\s+disable\b'
|
|
174
|
+
reason: gcloud services disable (disables GCP APIs)
|
|
175
|
+
- pattern: '\bgcloud\s+iam\s+roles\s+delete\b'
|
|
176
|
+
reason: gcloud iam roles delete
|
|
177
|
+
- pattern: '\bgcloud\s+iam\s+policies\b'
|
|
178
|
+
reason: gcloud iam policies (modifies IAM policies)
|
|
179
|
+
ask: true
|
|
180
|
+
|
|
181
|
+
# -- Firebase --
|
|
182
|
+
- pattern: '\bfirebase\s+projects:delete\b'
|
|
183
|
+
reason: firebase projects:delete (deletes entire project)
|
|
184
|
+
- pattern: '\bfirebase\s+firestore:delete\s+.*--all-collections'
|
|
185
|
+
reason: firebase firestore:delete --all-collections (wipes all data)
|
|
186
|
+
- pattern: '\bfirebase\s+database:remove\b'
|
|
187
|
+
reason: firebase database:remove (wipes Realtime DB)
|
|
188
|
+
- pattern: '\bfirebase\s+hosting:disable\b'
|
|
189
|
+
reason: firebase hosting:disable
|
|
190
|
+
- pattern: '\bfirebase\s+functions:delete\b'
|
|
191
|
+
reason: firebase functions:delete
|
|
192
|
+
|
|
193
|
+
# -- Vercel --
|
|
194
|
+
- pattern: '\bvercel\s+remove\s+.*--yes'
|
|
195
|
+
reason: vercel remove --yes (removes deployment)
|
|
196
|
+
- pattern: '\bvercel\s+projects\s+rm\b'
|
|
197
|
+
reason: vercel projects rm (deletes project)
|
|
198
|
+
- pattern: '\bvercel\s+env\s+rm\b'
|
|
199
|
+
reason: vercel env rm (removes env variables)
|
|
200
|
+
- pattern: '\bvercel\s+rm\b'
|
|
201
|
+
reason: vercel rm (removes deployment)
|
|
202
|
+
- pattern: '\bvercel\s+remove\b'
|
|
203
|
+
reason: vercel remove (removes deployment)
|
|
204
|
+
- pattern: '\bvercel\s+domains\s+rm\b'
|
|
205
|
+
reason: vercel domains rm (removes custom domain)
|
|
206
|
+
|
|
207
|
+
# -- Netlify --
|
|
208
|
+
- pattern: '\bnetlify\s+sites:delete\b'
|
|
209
|
+
reason: netlify sites:delete (deletes entire site)
|
|
210
|
+
- pattern: '\bnetlify\s+functions:delete\b'
|
|
211
|
+
reason: netlify functions:delete
|
|
212
|
+
|
|
213
|
+
# -- Cloudflare --
|
|
214
|
+
- pattern: '\bwrangler\s+delete\b'
|
|
215
|
+
reason: wrangler delete (deletes Worker)
|
|
216
|
+
- pattern: '\bwrangler\s+r2\s+bucket\s+delete\b'
|
|
217
|
+
reason: wrangler r2 bucket delete
|
|
218
|
+
- pattern: '\bwrangler\s+kv:namespace\s+delete\b'
|
|
219
|
+
reason: wrangler kv:namespace delete
|
|
220
|
+
- pattern: '\bwrangler\s+d1\s+delete\b'
|
|
221
|
+
reason: wrangler d1 delete (deletes database)
|
|
222
|
+
- pattern: '\bwrangler\s+queues\s+delete\b'
|
|
223
|
+
reason: wrangler queues delete
|
|
224
|
+
|
|
225
|
+
# -- SQL --
|
|
226
|
+
- pattern: 'DELETE\s+FROM\s+\w+\s*;'
|
|
227
|
+
reason: DELETE without WHERE clause (will delete ALL rows)
|
|
228
|
+
- pattern: 'DELETE\s+\*\s+FROM'
|
|
229
|
+
reason: DELETE * (will delete ALL rows)
|
|
230
|
+
- pattern: '\bTRUNCATE\s+TABLE\b'
|
|
231
|
+
reason: TRUNCATE TABLE (will delete ALL rows)
|
|
232
|
+
- pattern: '\bDROP\s+TABLE\b'
|
|
233
|
+
reason: DROP TABLE
|
|
234
|
+
- pattern: '\bDROP\s+DATABASE\b'
|
|
235
|
+
reason: DROP DATABASE
|
|
236
|
+
- pattern: '\bDROP\s+SCHEMA\b'
|
|
237
|
+
reason: DROP SCHEMA
|
|
238
|
+
- pattern: '\bDELETE\s+FROM\s+\w+\s+WHERE\b.*\bid\s*='
|
|
239
|
+
reason: SQL DELETE with specific ID
|
|
240
|
+
ask: true
|
|
241
|
+
|
|
242
|
+
askAccessPaths: []
|
|
243
|
+
|
|
244
|
+
readOnlyPaths:
|
|
245
|
+
- /etc/
|
|
246
|
+
- /usr/
|
|
247
|
+
- /bin/
|
|
248
|
+
- /sbin/
|
|
249
|
+
- /boot/
|
|
250
|
+
- /root/
|
|
251
|
+
- ~/.bash_history
|
|
252
|
+
- ~/.zsh_history
|
|
253
|
+
- ~/.node_repl_history
|
|
254
|
+
- ~/.bashrc
|
|
255
|
+
- ~/.zshrc
|
|
256
|
+
- ~/.profile
|
|
257
|
+
- ~/.bash_profile
|
|
258
|
+
- "package-lock.json"
|
|
259
|
+
- "yarn.lock"
|
|
260
|
+
- "pnpm-lock.yaml"
|
|
261
|
+
- "Gemfile.lock"
|
|
262
|
+
- "poetry.lock"
|
|
263
|
+
- "Pipfile.lock"
|
|
264
|
+
- "composer.lock"
|
|
265
|
+
- "Cargo.lock"
|
|
266
|
+
- "go.sum"
|
|
267
|
+
- "flake.lock"
|
|
268
|
+
- "bun.lockb"
|
|
269
|
+
- "uv.lock"
|
|
270
|
+
- "npm-shrinkwrap.json"
|
|
271
|
+
- "*.lock"
|
|
272
|
+
- "*.lockb"
|
|
273
|
+
- "*.min.js"
|
|
274
|
+
- "*.min.css"
|
|
275
|
+
- "*.bundle.js"
|
|
276
|
+
- "*.chunk.js"
|
|
277
|
+
- dist/
|
|
278
|
+
- build/
|
|
279
|
+
- .next/
|
|
280
|
+
- .nuxt/
|
|
281
|
+
- .output/
|
|
282
|
+
- node_modules/
|
|
283
|
+
- __pycache__/
|
|
284
|
+
- .venv/
|
|
285
|
+
- venv/
|
|
286
|
+
- target/
|
|
287
|
+
|
|
288
|
+
noDeletePaths:
|
|
289
|
+
- ~/.claude/
|
|
290
|
+
- ~/.pi/
|
|
291
|
+
- CLAUDE.md
|
|
292
|
+
- "LICENSE"
|
|
293
|
+
- "LICENSE.*"
|
|
294
|
+
- "COPYING"
|
|
295
|
+
- "COPYING.*"
|
|
296
|
+
- "NOTICE"
|
|
297
|
+
- "PATENTS"
|
|
298
|
+
- "README.md"
|
|
299
|
+
- "README.*"
|
|
300
|
+
- "CONTRIBUTING.md"
|
|
301
|
+
- "CHANGELOG.md"
|
|
302
|
+
- "CODE_OF_CONDUCT.md"
|
|
303
|
+
- "SECURITY.md"
|
|
304
|
+
- .git/
|
|
305
|
+
- .gitignore
|
|
306
|
+
- .gitattributes
|
|
307
|
+
- .gitmodules
|
|
308
|
+
- .github/
|
|
309
|
+
- .gitlab-ci.yml
|
|
310
|
+
- .circleci/
|
|
311
|
+
- Jenkinsfile
|
|
312
|
+
- .travis.yml
|
|
313
|
+
- azure-pipelines.yml
|
|
314
|
+
- Dockerfile
|
|
315
|
+
- "Dockerfile.*"
|
|
316
|
+
- docker-compose.yml
|
|
317
|
+
- "docker-compose.*.yml"
|
|
318
|
+
- .dockerignore
|