@probelabs/probe 0.6.0-rc256 → 0.6.0-rc258

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/README.md CHANGED
@@ -91,7 +91,7 @@ const agent = new ProbeAgent({
91
91
  sessionId: 'my-session', // Optional: for conversation continuity
92
92
  path: '/path/to/your/project',
93
93
  provider: 'anthropic', // or 'openai', 'google'
94
- model: 'claude-3-5-sonnet-20241022', // Optional: override model
94
+ model: 'claude-sonnet-4-6', // Optional: override model
95
95
  allowEdit: true, // Optional: enable edit + create tools for code modification
96
96
  debug: true, // Optional: enable debug logging
97
97
  allowedTools: ['*'], // Optional: filter available tools (see Tool Filtering below)
@@ -128,7 +128,7 @@ export GOOGLE_API_KEY=your_google_key
128
128
  export FORCE_PROVIDER=anthropic
129
129
 
130
130
  # Optional: Override model name
131
- export MODEL_NAME=claude-3-5-sonnet-20241022
131
+ export MODEL_NAME=claude-sonnet-4-6
132
132
  ```
133
133
 
134
134
  **ProbeAgent Features:**
@@ -204,12 +204,12 @@ const agent = new ProbeAgent({
204
204
  region: 'us-west-2',
205
205
  accessKeyId: process.env.AWS_ACCESS_KEY_ID,
206
206
  secretAccessKey: process.env.AWS_SECRET_ACCESS_KEY,
207
- model: 'anthropic.claude-sonnet-4-20250514-v1:0'
207
+ model: 'anthropic.claude-sonnet-4-6'
208
208
  },
209
209
  {
210
210
  provider: 'openai',
211
211
  apiKey: process.env.OPENAI_API_KEY,
212
- model: 'gpt-4o'
212
+ model: 'gpt-5.2'
213
213
  }
214
214
  ],
215
215
  maxTotalAttempts: 15 // Maximum attempts across all providers
@@ -919,7 +919,7 @@ const extractTool = tools.createExtractTool();
919
919
 
920
920
  // Create a ChatOpenAI instance with tools
921
921
  const model = new ChatOpenAI({
922
- modelName: "gpt-4o",
922
+ modelName: "gpt-5.2",
923
923
  temperature: 0.7
924
924
  }).withTools([searchTool, queryTool, extractTool]);
925
925
 
@@ -41,10 +41,10 @@ export const FALLBACK_STRATEGIES = {
41
41
  * Default model mappings for each provider
42
42
  */
43
43
  const DEFAULT_MODELS = {
44
- anthropic: 'claude-sonnet-4-5-20250929',
45
- openai: 'gpt-4o',
46
- google: 'gemini-2.0-flash-exp',
47
- bedrock: 'anthropic.claude-sonnet-4-20250514-v1:0'
44
+ anthropic: 'claude-sonnet-4-6',
45
+ openai: 'gpt-5.2',
46
+ google: 'gemini-2.5-flash',
47
+ bedrock: 'anthropic.claude-sonnet-4-6'
48
48
  };
49
49
 
50
50
  /**
@@ -719,7 +719,7 @@ export class ProbeAgent {
719
719
  // Set provider to claude-code
720
720
  this.clientApiProvider = 'claude-code';
721
721
  this.provider = null;
722
- this.model = this.clientApiModel || 'claude-3-5-sonnet-20241022';
722
+ this.model = this.clientApiModel || 'claude-sonnet-4-6';
723
723
  this.apiType = 'claude-code';
724
724
  } else if (codexAvailable) {
725
725
  if (this.debug) {
@@ -729,7 +729,7 @@ export class ProbeAgent {
729
729
  // Set provider to codex
730
730
  this.clientApiProvider = 'codex';
731
731
  this.provider = null;
732
- this.model = this.clientApiModel || 'gpt-4o';
732
+ this.model = this.clientApiModel || 'gpt-5.2';
733
733
  this.apiType = 'codex';
734
734
  } else {
735
735
  // Neither API keys nor CLI commands available
@@ -1041,7 +1041,7 @@ export class ProbeAgent {
1041
1041
  // Claude Code engine will be initialized lazily in getEngine()
1042
1042
  // Set minimal defaults for compatibility
1043
1043
  this.provider = null;
1044
- this.model = modelName || 'claude-3-5-sonnet-20241022';
1044
+ this.model = modelName || 'claude-sonnet-4-6';
1045
1045
  this.apiType = 'claude-code';
1046
1046
  if (this.debug) {
1047
1047
  console.log('[DEBUG] Claude Code engine selected - will use built-in access if available');
@@ -1499,7 +1499,7 @@ export class ProbeAgent {
1499
1499
  apiKey: apiKey,
1500
1500
  ...(apiUrl && { baseURL: apiUrl }),
1501
1501
  });
1502
- this.model = modelName || 'claude-sonnet-4-5-20250929';
1502
+ this.model = modelName || 'claude-sonnet-4-6';
1503
1503
  this.apiType = 'anthropic';
1504
1504
 
1505
1505
  if (this.debug) {
@@ -1516,7 +1516,7 @@ export class ProbeAgent {
1516
1516
  apiKey: apiKey,
1517
1517
  ...(apiUrl && { baseURL: apiUrl }),
1518
1518
  });
1519
- this.model = modelName || 'gpt-5-thinking';
1519
+ this.model = modelName || 'gpt-5.2';
1520
1520
  this.apiType = 'openai';
1521
1521
 
1522
1522
  if (this.debug) {
@@ -1646,7 +1646,7 @@ export class ProbeAgent {
1646
1646
  }
1647
1647
 
1648
1648
  this.provider = createAmazonBedrock(config);
1649
- this.model = modelName || 'anthropic.claude-sonnet-4-20250514-v1:0';
1649
+ this.model = modelName || 'anthropic.claude-sonnet-4-6';
1650
1650
  this.apiType = 'bedrock';
1651
1651
 
1652
1652
  if (this.debug) {
@@ -1715,7 +1715,7 @@ export class ProbeAgent {
1715
1715
  sessionId: this.options?.sessionId,
1716
1716
  debug: this.debug,
1717
1717
  allowedTools: this.allowedTools, // Pass tool filtering configuration
1718
- model: this.model // Pass model name (e.g., gpt-4o, o3, etc.)
1718
+ model: this.model // Pass model name (e.g., gpt-5.2, o3, etc.)
1719
1719
  });
1720
1720
  if (this.debug) {
1721
1721
  console.log('[DEBUG] Using Codex CLI engine with Probe tools');
@@ -3249,9 +3249,7 @@ Follow these instructions carefully:
3249
3249
  if (!maxResponseTokens) {
3250
3250
  // Use model-based defaults if not explicitly configured
3251
3251
  maxResponseTokens = 4000;
3252
- if (this.model && this.model.includes('opus') || this.model && this.model.includes('sonnet') || this.model && this.model.startsWith('gpt-4-')) {
3253
- maxResponseTokens = 8192;
3254
- } else if (this.model && this.model.startsWith('gpt-4o')) {
3252
+ if (this.model && this.model.includes('opus') || this.model && this.model.includes('sonnet') || this.model && this.model.startsWith('gpt-4') || this.model && this.model.startsWith('gpt-5')) {
3255
3253
  maxResponseTokens = 8192;
3256
3254
  } else if (this.model && this.model.startsWith('gemini')) {
3257
3255
  maxResponseTokens = 32000;
@@ -1,6 +1,14 @@
1
1
  /**
2
2
  * Default allow and deny patterns for bash command execution
3
3
  * @module agent/bashDefaults
4
+ *
5
+ * Pattern syntax: colon-separated parts matching command + args.
6
+ * 'git:push' — matches 'git push', 'git push origin main', etc.
7
+ * 'git:push:--force' — matches 'git push --force ...'
8
+ * 'git:branch:*' — wildcard matches any arg (or no arg) at that position
9
+ *
10
+ * NOTE: 'X' and 'X:*' are functionally identical — the shorter form is preferred.
11
+ * A pattern only checks the parts it specifies; extra args are ignored.
4
12
  */
5
13
 
6
14
  /**
@@ -8,68 +16,68 @@
8
16
  */
9
17
  export const DEFAULT_ALLOW_PATTERNS = [
10
18
  // Basic navigation and listing
11
- 'ls', 'dir', 'pwd', 'cd', 'cd:*',
12
-
19
+ 'ls', 'dir', 'pwd', 'cd',
20
+
13
21
  // File reading commands
14
- 'cat', 'cat:*', 'head', 'head:*', 'tail', 'tail:*',
22
+ 'cat', 'head', 'tail',
15
23
  'less', 'more', 'view',
16
-
24
+
17
25
  // File information and metadata
18
- 'file', 'file:*', 'stat', 'stat:*', 'wc', 'wc:*',
19
- 'du', 'du:*', 'df', 'df:*', 'realpath', 'realpath:*',
20
-
21
- // Search and find commands (read-only) - find restricted to safe operations
22
- 'find', 'find:-name:*', 'find:-type:*', 'find:-size:*', 'find:-mtime:*', 'find:-newer:*',
23
- 'find:-path:*', 'find:-iname:*', 'find:-maxdepth:*', 'find:-mindepth:*', 'find:-print',
24
- 'grep', 'grep:*', 'egrep', 'egrep:*', 'fgrep', 'fgrep:*',
25
- 'rg', 'rg:*', 'ag', 'ag:*', 'ack', 'ack:*',
26
- 'which', 'which:*', 'whereis', 'whereis:*', 'locate', 'locate:*',
27
- 'type', 'type:*', 'command', 'command:*',
28
-
26
+ 'file', 'stat', 'wc',
27
+ 'du', 'df', 'realpath',
28
+
29
+ // Search and find commands (read-only)
30
+ // Note: bare 'find' allows all find variants; dangerous ones (find -exec) are blocked by deny list
31
+ 'find',
32
+ 'grep', 'egrep', 'fgrep',
33
+ 'rg', 'ag', 'ack',
34
+ 'which', 'whereis', 'locate',
35
+ 'type', 'command',
36
+
29
37
  // Tree and structure visualization
30
- 'tree', 'tree:*',
31
-
38
+ 'tree',
39
+
32
40
  // Git read-only operations
33
- 'git:status', 'git:status:*', 'git:log', 'git:log:*', 'git:diff', 'git:diff:*',
34
- 'git:show', 'git:show:*', 'git:branch', 'git:branch:*',
35
- 'git:tag', 'git:tag:*', 'git:describe', 'git:describe:*',
36
- 'git:remote', 'git:remote:*', 'git:config:*',
37
- 'git:blame', 'git:blame:*', 'git:shortlog', 'git:shortlog:*', 'git:reflog', 'git:reflog:*',
38
- 'git:ls-files', 'git:ls-files:*', 'git:ls-tree', 'git:ls-tree:*',
39
- 'git:ls-remote', 'git:ls-remote:*',
40
- 'git:rev-parse', 'git:rev-parse:*', 'git:rev-list', 'git:rev-list:*',
41
- 'git:cat-file', 'git:cat-file:*',
42
- 'git:diff-tree', 'git:diff-tree:*', 'git:diff-files', 'git:diff-files:*',
43
- 'git:diff-index', 'git:diff-index:*',
44
- 'git:for-each-ref', 'git:for-each-ref:*',
45
- 'git:merge-base', 'git:merge-base:*',
46
- 'git:name-rev', 'git:name-rev:*',
47
- 'git:count-objects', 'git:count-objects:*',
48
- 'git:verify-commit', 'git:verify-commit:*', 'git:verify-tag', 'git:verify-tag:*',
49
- 'git:check-ignore', 'git:check-ignore:*', 'git:check-attr', 'git:check-attr:*',
50
- 'git:stash:list', 'git:stash:show', 'git:stash:show:*',
51
- 'git:worktree:list', 'git:worktree:list:*',
52
- 'git:notes:list', 'git:notes:show', 'git:notes:show:*',
53
- 'git:--version', 'git:help', 'git:help:*',
41
+ 'git:status', 'git:log', 'git:diff',
42
+ 'git:show', 'git:branch',
43
+ 'git:tag', 'git:describe',
44
+ 'git:remote', 'git:config',
45
+ 'git:blame', 'git:shortlog', 'git:reflog',
46
+ 'git:ls-files', 'git:ls-tree',
47
+ 'git:ls-remote',
48
+ 'git:rev-parse', 'git:rev-list',
49
+ 'git:cat-file',
50
+ 'git:diff-tree', 'git:diff-files',
51
+ 'git:diff-index',
52
+ 'git:for-each-ref',
53
+ 'git:merge-base',
54
+ 'git:name-rev',
55
+ 'git:count-objects',
56
+ 'git:verify-commit', 'git:verify-tag',
57
+ 'git:check-ignore', 'git:check-attr',
58
+ 'git:stash:list', 'git:stash:show',
59
+ 'git:worktree:list',
60
+ 'git:notes:list', 'git:notes:show',
61
+ 'git:--version', 'git:help',
54
62
 
55
63
  // GitHub CLI (gh) read-only operations
56
- 'gh:--version', 'gh:help', 'gh:help:*', 'gh:status',
57
- 'gh:auth:status', 'gh:auth:status:*',
58
- 'gh:issue:list', 'gh:issue:list:*', 'gh:issue:view', 'gh:issue:view:*',
59
- 'gh:issue:status', 'gh:issue:status:*',
60
- 'gh:pr:list', 'gh:pr:list:*', 'gh:pr:view', 'gh:pr:view:*',
61
- 'gh:pr:status', 'gh:pr:status:*', 'gh:pr:diff', 'gh:pr:diff:*',
62
- 'gh:pr:checks', 'gh:pr:checks:*',
63
- 'gh:repo:list', 'gh:repo:list:*', 'gh:repo:view', 'gh:repo:view:*',
64
- 'gh:release:list', 'gh:release:list:*', 'gh:release:view', 'gh:release:view:*',
65
- 'gh:run:list', 'gh:run:list:*', 'gh:run:view', 'gh:run:view:*',
66
- 'gh:workflow:list', 'gh:workflow:list:*', 'gh:workflow:view', 'gh:workflow:view:*',
67
- 'gh:gist:list', 'gh:gist:list:*', 'gh:gist:view', 'gh:gist:view:*',
68
- 'gh:search:issues', 'gh:search:issues:*', 'gh:search:prs', 'gh:search:prs:*',
69
- 'gh:search:repos', 'gh:search:repos:*', 'gh:search:code', 'gh:search:code:*',
70
- 'gh:search:commits', 'gh:search:commits:*',
71
- 'gh:api', 'gh:api:*',
72
-
64
+ 'gh:--version', 'gh:help', 'gh:status',
65
+ 'gh:auth:status',
66
+ 'gh:issue:list', 'gh:issue:view',
67
+ 'gh:issue:status',
68
+ 'gh:pr:list', 'gh:pr:view',
69
+ 'gh:pr:status', 'gh:pr:diff',
70
+ 'gh:pr:checks',
71
+ 'gh:repo:list', 'gh:repo:view',
72
+ 'gh:release:list', 'gh:release:view',
73
+ 'gh:run:list', 'gh:run:view',
74
+ 'gh:workflow:list', 'gh:workflow:view',
75
+ 'gh:gist:list', 'gh:gist:view',
76
+ 'gh:search:issues', 'gh:search:prs',
77
+ 'gh:search:repos', 'gh:search:code',
78
+ 'gh:search:commits',
79
+ 'gh:api',
80
+
73
81
  // Package managers (information only)
74
82
  'npm:list', 'npm:ls', 'npm:view', 'npm:info', 'npm:show',
75
83
  'npm:outdated', 'npm:audit', 'npm:--version',
@@ -80,7 +88,7 @@ export const DEFAULT_ALLOW_PATTERNS = [
80
88
  'gem:list', 'gem:--version',
81
89
  'bundle:list', 'bundle:show', 'bundle:--version',
82
90
  'composer:show', 'composer:--version',
83
-
91
+
84
92
  // Language and runtime versions
85
93
  'node:--version', 'node:-v',
86
94
  'python:--version', 'python:-V', 'python3:--version', 'python3:-V',
@@ -90,51 +98,51 @@ export const DEFAULT_ALLOW_PATTERNS = [
90
98
  'java:--version', 'java:-version', 'javac:--version',
91
99
  'mvn:--version', 'gradle:--version',
92
100
  'php:--version', 'dotnet:--version', 'dotnet:list',
93
-
101
+
94
102
  // Database client versions (connection info only)
95
103
  'psql:--version', 'mysql:--version', 'redis-cli:--version',
96
104
  'mongo:--version', 'sqlite3:--version',
97
-
105
+
98
106
  // System information
99
- 'uname', 'uname:*', 'hostname', 'whoami', 'id', 'groups',
100
- 'date', 'cal', 'uptime', 'w', 'users', 'sleep', 'sleep:*',
101
-
107
+ 'uname', 'hostname', 'whoami', 'id', 'groups',
108
+ 'date', 'cal', 'uptime', 'w', 'users', 'sleep',
109
+
102
110
  // Environment and shell
103
- 'env', 'printenv', 'echo', 'echo:*', 'printf', 'printf:*',
104
- 'export', 'export:*', 'set', 'unset',
105
-
111
+ 'env', 'printenv', 'echo', 'printf',
112
+ 'export', 'set', 'unset',
113
+
106
114
  // Process information (read-only)
107
- 'ps', 'ps:*', 'pgrep', 'pgrep:*', 'jobs', 'top:-n:1',
108
-
115
+ 'ps', 'pgrep', 'jobs', 'top:-n:1',
116
+
109
117
  // Network information (read-only)
110
118
  'ifconfig', 'ip:addr', 'ip:link', 'hostname:-I',
111
119
  'ping:-c:*', 'traceroute', 'nslookup', 'dig',
112
-
120
+
113
121
  // Text processing and utilities (awk removed - too powerful)
114
- 'sed:-n:*', 'cut', 'cut:*', 'sort', 'sort:*',
115
- 'uniq', 'uniq:*', 'tr', 'tr:*', 'column', 'column:*',
116
- 'paste', 'paste:*', 'join', 'join:*', 'comm', 'comm:*',
117
- 'diff', 'diff:*', 'cmp', 'cmp:*', 'patch:--dry-run:*',
118
-
122
+ 'sed:-n:*', 'cut', 'sort',
123
+ 'uniq', 'tr', 'column',
124
+ 'paste', 'join', 'comm',
125
+ 'diff', 'cmp', 'patch:--dry-run:*',
126
+
119
127
  // Hashing and encoding (read-only)
120
- 'md5sum', 'md5sum:*', 'sha1sum', 'sha1sum:*', 'sha256sum', 'sha256sum:*',
121
- 'base64', 'base64:-d', 'od', 'od:*', 'hexdump', 'hexdump:*',
122
-
128
+ 'md5sum', 'sha1sum', 'sha256sum',
129
+ 'base64', 'base64:-d', 'od', 'hexdump',
130
+
123
131
  // Archive and compression (list/view only)
124
132
  'tar:-tf:*', 'tar:-tzf:*', 'unzip:-l:*', 'zip:-l:*',
125
133
  'gzip:-l:*', 'gunzip:-l:*',
126
-
134
+
127
135
  // Help and documentation
128
- 'man', 'man:*', '--help', 'help', 'info', 'info:*',
129
- 'whatis', 'whatis:*', 'apropos', 'apropos:*',
130
-
136
+ 'man', '--help', 'help', 'info',
137
+ 'whatis', 'apropos',
138
+
131
139
  // Make (dry run and info)
132
140
  'make:-n', 'make:--dry-run', 'make:-p', 'make:--print-data-base',
133
-
141
+
134
142
  // Docker (read-only operations)
135
143
  'docker:ps', 'docker:images', 'docker:version', 'docker:info',
136
144
  'docker:logs:*', 'docker:inspect:*',
137
-
145
+
138
146
  // Test runners (list/info only)
139
147
  'jest:--listTests', 'mocha:--help', 'pytest:--collect-only'
140
148
  ];
@@ -144,21 +152,22 @@ export const DEFAULT_ALLOW_PATTERNS = [
144
152
  */
145
153
  export const DEFAULT_DENY_PATTERNS = [
146
154
  // Dangerous file operations
147
- 'rm:-rf', 'rm:-f:/', 'rm:/', 'rm:-rf:*', 'rmdir',
155
+ 'rm:-rf', 'rm:-f:/', 'rm:/', 'rmdir',
148
156
  'chmod:777', 'chmod:-R:777', 'chown', 'chgrp',
149
- 'dd', 'dd:*', 'shred', 'shred:*',
150
-
157
+ 'dd', 'shred',
158
+
151
159
  // Dangerous find operations that can execute arbitrary commands
152
- 'find:-exec:*', 'find:*:-exec:*', 'find:-execdir:*', 'find:*:-execdir:*',
153
- 'find:-ok:*', 'find:*:-ok:*', 'find:-okdir:*', 'find:*:-okdir:*',
154
-
160
+ 'find:-exec', 'find:*:-exec', 'find:-execdir', 'find:*:-execdir',
161
+ 'find:-ok', 'find:*:-ok', 'find:-okdir', 'find:*:-okdir',
162
+
155
163
  // Powerful scripting tools that can execute arbitrary commands
156
- 'awk', 'awk:*', 'perl', 'perl:*', 'python:-c:*', 'node:-e:*',
157
-
164
+ 'awk', 'perl', 'python:-c:*', 'node:-e:*',
165
+
158
166
  // System administration and modification
159
- 'sudo:*', 'su', 'su:*', 'passwd', 'adduser', 'useradd',
167
+ 'sudo', 'su',
168
+ 'passwd', 'adduser', 'useradd',
160
169
  'userdel', 'usermod', 'groupadd', 'groupdel', 'visudo',
161
-
170
+
162
171
  // Package installation and removal
163
172
  'npm:install', 'npm:i', 'npm:uninstall', 'npm:publish',
164
173
  'npm:unpublish', 'npm:link', 'npm:update',
@@ -169,103 +178,103 @@ export const DEFAULT_DENY_PATTERNS = [
169
178
  'gem:install', 'gem:uninstall', 'gem:update',
170
179
  'bundle:install', 'bundle:update',
171
180
  'composer:install', 'composer:update', 'composer:remove',
172
- 'apt:*', 'apt-get:*', 'yum:*', 'dnf:*', 'zypper:*',
181
+ 'apt', 'apt-get', 'yum', 'dnf', 'zypper',
173
182
  'brew:install', 'brew:uninstall', 'brew:upgrade',
174
183
  'conda:install', 'conda:remove', 'conda:update',
175
-
184
+
176
185
  // Service and system control
177
- 'systemctl:*', 'service:*', 'chkconfig:*',
178
- 'initctl:*', 'upstart:*',
179
-
186
+ 'systemctl', 'service', 'chkconfig',
187
+ 'initctl', 'upstart',
188
+
180
189
  // Network operations that could be dangerous
181
190
  'curl:-d:*', 'curl:--data:*', 'curl:-X:POST:*', 'curl:-X:PUT:*',
182
191
  'wget:-O:/', 'wget:--post-data:*',
183
- 'ssh', 'ssh:*', 'scp', 'scp:*', 'sftp', 'sftp:*', 'rsync:*',
184
- 'nc', 'nc:*', 'netcat', 'netcat:*', 'telnet', 'telnet:*',
185
- 'ftp', 'ftp:*',
186
-
192
+ 'ssh', 'scp', 'sftp', 'rsync',
193
+ 'nc', 'netcat', 'telnet',
194
+ 'ftp',
195
+
187
196
  // Process control and termination
188
- 'kill', 'kill:*', 'killall', 'killall:*', 'pkill', 'pkill:*',
189
- 'nohup:*', 'disown:*',
190
-
197
+ 'kill', 'killall', 'pkill',
198
+ 'nohup', 'disown',
199
+
191
200
  // System control and shutdown
192
- 'shutdown', 'shutdown:*', 'reboot', 'halt', 'poweroff',
201
+ 'shutdown', 'reboot', 'halt', 'poweroff',
193
202
  'init', 'telinit',
194
-
203
+
195
204
  // Kernel and module operations
196
- 'insmod', 'insmod:*', 'rmmod', 'rmmod:*', 'modprobe', 'modprobe:*',
205
+ 'insmod', 'rmmod', 'modprobe',
197
206
  'sysctl:-w:*',
198
-
207
+
199
208
  // Dangerous git operations
200
- 'git:push', 'git:push:*', 'git:force', 'git:reset', 'git:reset:*',
201
- 'git:clean', 'git:clean:*', 'git:rm', 'git:rm:*',
202
- 'git:commit', 'git:commit:*', 'git:merge', 'git:merge:*',
203
- 'git:rebase', 'git:rebase:*', 'git:cherry-pick', 'git:cherry-pick:*',
204
- 'git:stash:drop', 'git:stash:drop:*', 'git:stash:pop', 'git:stash:pop:*',
205
- 'git:stash:push', 'git:stash:push:*', 'git:stash:clear',
206
- 'git:branch:-d', 'git:branch:-d:*', 'git:branch:-D', 'git:branch:-D:*',
207
- 'git:branch:--delete', 'git:branch:--delete:*',
208
- 'git:tag:-d', 'git:tag:-d:*', 'git:tag:--delete', 'git:tag:--delete:*',
209
- 'git:remote:remove', 'git:remote:remove:*', 'git:remote:rm', 'git:remote:rm:*',
210
- 'git:checkout:--force', 'git:checkout:--force:*',
211
- 'git:checkout:-f', 'git:checkout:-f:*',
212
- 'git:submodule:deinit', 'git:submodule:deinit:*',
213
- 'git:notes:add', 'git:notes:add:*', 'git:notes:remove', 'git:notes:remove:*',
214
- 'git:worktree:add', 'git:worktree:add:*',
215
- 'git:worktree:remove', 'git:worktree:remove:*',
209
+ 'git:push', 'git:force', 'git:reset',
210
+ 'git:clean', 'git:rm',
211
+ 'git:commit', 'git:merge',
212
+ 'git:rebase', 'git:cherry-pick',
213
+ 'git:stash:drop', 'git:stash:pop',
214
+ 'git:stash:push', 'git:stash:clear',
215
+ 'git:branch:-d', 'git:branch:-D',
216
+ 'git:branch:--delete',
217
+ 'git:tag:-d', 'git:tag:--delete',
218
+ 'git:remote:remove', 'git:remote:rm',
219
+ 'git:checkout:--force',
220
+ 'git:checkout:-f',
221
+ 'git:submodule:deinit',
222
+ 'git:notes:add', 'git:notes:remove',
223
+ 'git:worktree:add',
224
+ 'git:worktree:remove',
216
225
 
217
226
  // Dangerous GitHub CLI (gh) write operations
218
- 'gh:issue:create', 'gh:issue:create:*', 'gh:issue:close', 'gh:issue:close:*',
219
- 'gh:issue:delete', 'gh:issue:delete:*', 'gh:issue:edit', 'gh:issue:edit:*',
220
- 'gh:issue:reopen', 'gh:issue:reopen:*',
221
- 'gh:issue:comment', 'gh:issue:comment:*',
222
- 'gh:pr:create', 'gh:pr:create:*', 'gh:pr:close', 'gh:pr:close:*',
223
- 'gh:pr:merge', 'gh:pr:merge:*', 'gh:pr:edit', 'gh:pr:edit:*',
224
- 'gh:pr:reopen', 'gh:pr:reopen:*', 'gh:pr:review', 'gh:pr:review:*',
225
- 'gh:pr:comment', 'gh:pr:comment:*',
226
- 'gh:repo:create', 'gh:repo:create:*', 'gh:repo:delete', 'gh:repo:delete:*',
227
- 'gh:repo:fork', 'gh:repo:fork:*', 'gh:repo:rename', 'gh:repo:rename:*',
228
- 'gh:repo:archive', 'gh:repo:archive:*', 'gh:repo:clone', 'gh:repo:clone:*',
229
- 'gh:release:create', 'gh:release:create:*', 'gh:release:delete', 'gh:release:delete:*',
230
- 'gh:release:edit', 'gh:release:edit:*',
231
- 'gh:run:cancel', 'gh:run:cancel:*', 'gh:run:rerun', 'gh:run:rerun:*',
232
- 'gh:workflow:run', 'gh:workflow:run:*',
233
- 'gh:workflow:enable', 'gh:workflow:enable:*', 'gh:workflow:disable', 'gh:workflow:disable:*',
234
- 'gh:gist:create', 'gh:gist:create:*', 'gh:gist:delete', 'gh:gist:delete:*',
235
- 'gh:gist:edit', 'gh:gist:edit:*',
236
- 'gh:secret:set', 'gh:secret:set:*', 'gh:secret:delete', 'gh:secret:delete:*',
237
- 'gh:variable:set', 'gh:variable:set:*', 'gh:variable:delete', 'gh:variable:delete:*',
238
- 'gh:label:create', 'gh:label:create:*', 'gh:label:delete', 'gh:label:delete:*',
239
- 'gh:ssh-key:add', 'gh:ssh-key:add:*', 'gh:ssh-key:delete', 'gh:ssh-key:delete:*',
240
-
227
+ 'gh:issue:create', 'gh:issue:close',
228
+ 'gh:issue:delete', 'gh:issue:edit',
229
+ 'gh:issue:reopen',
230
+ 'gh:issue:comment',
231
+ 'gh:pr:create', 'gh:pr:close',
232
+ 'gh:pr:merge', 'gh:pr:edit',
233
+ 'gh:pr:reopen', 'gh:pr:review',
234
+ 'gh:pr:comment',
235
+ 'gh:repo:create', 'gh:repo:delete',
236
+ 'gh:repo:fork', 'gh:repo:rename',
237
+ 'gh:repo:archive', 'gh:repo:clone',
238
+ 'gh:release:create', 'gh:release:delete',
239
+ 'gh:release:edit',
240
+ 'gh:run:cancel', 'gh:run:rerun',
241
+ 'gh:workflow:run',
242
+ 'gh:workflow:enable', 'gh:workflow:disable',
243
+ 'gh:gist:create', 'gh:gist:delete',
244
+ 'gh:gist:edit',
245
+ 'gh:secret:set', 'gh:secret:delete',
246
+ 'gh:variable:set', 'gh:variable:delete',
247
+ 'gh:label:create', 'gh:label:delete',
248
+ 'gh:ssh-key:add', 'gh:ssh-key:delete',
249
+
241
250
  // File system mounting and partitioning
242
- 'mount', 'mount:*', 'umount', 'umount:*', 'fdisk', 'fdisk:*',
243
- 'parted', 'parted:*', 'mkfs', 'mkfs:*', 'fsck', 'fsck:*',
244
-
251
+ 'mount', 'umount', 'fdisk',
252
+ 'parted', 'mkfs', 'fsck',
253
+
245
254
  // Cron and scheduling
246
- 'crontab', 'crontab:*', 'at', 'at:*', 'batch', 'batch:*',
247
-
255
+ 'crontab', 'at', 'batch',
256
+
248
257
  // Compression with potential overwrite
249
- 'tar:-xf:*', 'unzip', 'unzip:*', 'gzip:*', 'gunzip:*',
250
-
258
+ 'tar:-xf:*', 'unzip', 'gzip', 'gunzip',
259
+
251
260
  // Build and compilation that might modify files
252
261
  'make', 'make:install', 'make:clean', 'cargo:build', 'cargo:install',
253
262
  'npm:run:build', 'yarn:build', 'mvn:install', 'gradle:build',
254
-
263
+
255
264
  // Docker operations that could modify state
256
- 'docker:run', 'docker:run:*', 'docker:exec', 'docker:exec:*',
257
- 'docker:build', 'docker:build:*', 'docker:pull', 'docker:push',
265
+ 'docker:run', 'docker:exec',
266
+ 'docker:build', 'docker:pull', 'docker:push',
258
267
  'docker:rm', 'docker:rmi', 'docker:stop', 'docker:start',
259
-
268
+
260
269
  // Database operations
261
270
  'mysql:-e:DROP', 'psql:-c:DROP', 'redis-cli:FLUSHALL',
262
271
  'mongo:--eval:*',
263
-
272
+
264
273
  // Text editors that could modify files
265
- 'vi', 'vi:*', 'vim', 'vim:*', 'nano', 'nano:*', 'emacs', 'emacs:*',
274
+ 'vi', 'vim', 'nano', 'emacs',
266
275
  'sed:-i:*', 'perl:-i:*',
267
-
276
+
268
277
  // Potentially dangerous utilities
269
- 'eval', 'eval:*', 'exec', 'exec:*', 'source', 'source:*',
278
+ 'eval', 'exec', 'source',
270
279
  'bash:-c:*', 'sh:-c:*', 'zsh:-c:*'
271
- ];
280
+ ];