oh-my-customcodex 0.3.8 → 0.3.10
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/cli/index.js +2 -2
- package/dist/index.js +2 -2
- package/package.json +1 -1
- package/templates/.claude/hooks/hooks.json +2 -2
- package/templates/.claude/hooks/scripts/claude-sensitive-path-guard.sh +9 -5
- package/templates/.claude/rules/MUST-agent-design.md +21 -1
- package/templates/.claude/skills/dev-review/SKILL.md +1 -1
- package/templates/.claude/skills/research/SKILL.md +1 -1
- package/templates/manifest.json +2 -2
package/dist/cli/index.js
CHANGED
|
@@ -3091,7 +3091,7 @@ var init_package = __esm(() => {
|
|
|
3091
3091
|
workspaces: [
|
|
3092
3092
|
"packages/*"
|
|
3093
3093
|
],
|
|
3094
|
-
version: "0.3.
|
|
3094
|
+
version: "0.3.10",
|
|
3095
3095
|
description: "Batteries-included agent harness on top of GPT Codex + OMX",
|
|
3096
3096
|
type: "module",
|
|
3097
3097
|
bin: {
|
|
@@ -26742,7 +26742,7 @@ function installCodex(deps = defaultDeps) {
|
|
|
26742
26742
|
if (os === "darwin") {
|
|
26743
26743
|
try {
|
|
26744
26744
|
info("codex.installing_brew");
|
|
26745
|
-
deps.exec("brew install
|
|
26745
|
+
deps.exec("brew install --cask codex", {
|
|
26746
26746
|
stdio: "inherit",
|
|
26747
26747
|
timeout: 120000
|
|
26748
26748
|
});
|
package/dist/index.js
CHANGED
|
@@ -1381,7 +1381,7 @@ function installCodex(deps = defaultDeps) {
|
|
|
1381
1381
|
if (os === "darwin") {
|
|
1382
1382
|
try {
|
|
1383
1383
|
info("codex.installing_brew");
|
|
1384
|
-
deps.exec("brew install
|
|
1384
|
+
deps.exec("brew install --cask codex", {
|
|
1385
1385
|
stdio: "inherit",
|
|
1386
1386
|
timeout: 120000
|
|
1387
1387
|
});
|
|
@@ -2180,7 +2180,7 @@ var package_default = {
|
|
|
2180
2180
|
workspaces: [
|
|
2181
2181
|
"packages/*"
|
|
2182
2182
|
],
|
|
2183
|
-
version: "0.3.
|
|
2183
|
+
version: "0.3.10",
|
|
2184
2184
|
description: "Batteries-included agent harness on top of GPT Codex + OMX",
|
|
2185
2185
|
type: "module",
|
|
2186
2186
|
bin: {
|
package/package.json
CHANGED
|
@@ -83,14 +83,14 @@
|
|
|
83
83
|
"description": "Schema-based tool input validation — Phase 1 advisory only"
|
|
84
84
|
},
|
|
85
85
|
{
|
|
86
|
-
"matcher": "tool == \"Bash\" && tool_input.command matches \"\\\\.claude/\"",
|
|
86
|
+
"matcher": "(tool == \"Bash\" && tool_input.command matches \"\\\\.claude/\") || ((tool == \"Write\" || tool == \"Edit\") && tool_input.file_path matches \"\\\\.claude/\")",
|
|
87
87
|
"hooks": [
|
|
88
88
|
{
|
|
89
89
|
"type": "command",
|
|
90
90
|
"command": "bash .codex/hooks/scripts/claude-sensitive-path-guard.sh"
|
|
91
91
|
}
|
|
92
92
|
],
|
|
93
|
-
"description": "Block Bash writes into .claude/ sensitive paths before Claude Code permission prompts fire"
|
|
93
|
+
"description": "Block Bash/Write/Edit writes into .claude/ sensitive paths before Claude Code permission prompts fire"
|
|
94
94
|
},
|
|
95
95
|
{
|
|
96
96
|
"matcher": "tool == \"Bash\"",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/bin/bash
|
|
2
|
-
# Block
|
|
2
|
+
# Block tool write operations targeting .claude/ sensitive paths.
|
|
3
3
|
# Claude Code can surface a sensitive-file permission prompt before allow rules
|
|
4
4
|
# or bypassPermissions are evaluated, so fail fast before the command runs.
|
|
5
5
|
|
|
@@ -8,11 +8,15 @@ set -euo pipefail
|
|
|
8
8
|
command -v jq >/dev/null 2>&1 || exit 0
|
|
9
9
|
|
|
10
10
|
input=$(cat)
|
|
11
|
+
tool=$(echo "$input" | jq -r '.tool // .tool_name // ""')
|
|
11
12
|
cmd=$(echo "$input" | jq -r '.tool_input.command // ""')
|
|
13
|
+
file_path=$(echo "$input" | jq -r '.tool_input.file_path // ""')
|
|
12
14
|
|
|
13
|
-
if [
|
|
14
|
-
echo "$
|
|
15
|
-
|
|
15
|
+
if [[ "$tool" =~ ^(Write|Edit)$ ]] && [[ "$file_path" =~ \.claude/ ]]; then
|
|
16
|
+
echo "[Hook] BLOCKED: $tool targeting .claude/ sensitive path" >&2
|
|
17
|
+
echo "[Hook] File: $file_path" >&2
|
|
18
|
+
echo "[Hook] Sensitive-path prompts can override allow rules. Use the repo's managed sync/update path or perform this change interactively." >&2
|
|
19
|
+
exit 2
|
|
16
20
|
fi
|
|
17
21
|
|
|
18
22
|
targets_claude=0
|
|
@@ -32,7 +36,7 @@ fi
|
|
|
32
36
|
if [ "$targets_claude" -eq 1 ] && [ "$writes_claude" -eq 1 ]; then
|
|
33
37
|
echo "[Hook] BLOCKED: Bash write targeting .claude/ sensitive path" >&2
|
|
34
38
|
echo "[Hook] Command: $cmd" >&2
|
|
35
|
-
echo "[Hook]
|
|
39
|
+
echo "[Hook] Sensitive-path prompts can override allow rules. Use the repo's managed sync/update path or perform this change interactively." >&2
|
|
36
40
|
exit 2
|
|
37
41
|
fi
|
|
38
42
|
|
|
@@ -232,9 +232,29 @@ Skills persist output to `.codex/outputs/sessions/{YYYY-MM-DD}/{skill-name}-{HHm
|
|
|
232
232
|
|
|
233
233
|
<!-- DETAIL: Artifact Output full spec
|
|
234
234
|
**Format**: Metadata header with `skill`, `date`, `query` fields, followed by skill output content.
|
|
235
|
-
**Rules**: Opt-in per skill, final subagent writes (R010 compliance),
|
|
235
|
+
**Rules**: Opt-in per skill, final subagent writes with a file-write API that creates missing parent directories (R010 compliance), do not pre-create session output directories with Bash, .codex/outputs/ is git-untracked, no indexing required.
|
|
236
236
|
-->
|
|
237
237
|
|
|
238
|
+
## Sensitive Path Handling
|
|
239
|
+
|
|
240
|
+
Claude Code treats `.claude/` and `templates/.claude/` as sensitive directories across Bash, Write, and Edit operations. The sensitive-path check runs above `bypassPermissions` and explicit allow rules, so allow rules do not override the sensitive-path check.
|
|
241
|
+
|
|
242
|
+
This Codex port uses `.codex/` as the active runtime surface, but packaged compatibility templates still live under `templates/.claude/`. Any automation that writes those templates must account for Claude Code permission prompts.
|
|
243
|
+
|
|
244
|
+
| Path pattern | Sensitive in Claude Code? | Affected operations |
|
|
245
|
+
|--------------|---------------------------|---------------------|
|
|
246
|
+
| `.claude/**` | Yes | Bash writes, Write, Edit |
|
|
247
|
+
| `templates/.claude/**` | Yes | Bash writes, Write, Edit |
|
|
248
|
+
| `.codex/**` | No | Normal Codex runtime writes; still follow R010/R017 |
|
|
249
|
+
| `.codex/outputs/**` and `.claude/outputs/**` | Treat as constrained artifact paths | Use file-write APIs that create parents; do not pre-create with Bash |
|
|
250
|
+
|
|
251
|
+
Recommended practice:
|
|
252
|
+
|
|
253
|
+
1. Prefer Write/Edit in an interactive session, or managed sync/update paths, over Bash copy/mkdir/tee writes for `.claude/` and `templates/.claude/`.
|
|
254
|
+
2. Keep allow rules only as defensive documentation; do not rely on them to suppress sensitive-path prompts.
|
|
255
|
+
3. Do not run unattended Claude Code release automation that writes `templates/.claude/**` unless the workflow can handle interactive approval.
|
|
256
|
+
4. In this Codex port, update `.codex/...` source files and their `templates/.claude/...` mirrors deliberately instead of bulk-copying with shell commands.
|
|
257
|
+
|
|
238
258
|
## Separation of Concerns
|
|
239
259
|
|
|
240
260
|
| Location | Purpose | Contains |
|
|
@@ -122,7 +122,7 @@ If only PASS/INFO: proceed automatically.
|
|
|
122
122
|
query: "{original user query}"
|
|
123
123
|
---
|
|
124
124
|
```
|
|
125
|
-
The review agent
|
|
125
|
+
The review agent writes the artifact file before returning results; use a file-write API that creates missing parent directories instead of any Bash directory-creation pre-step (R010 compliance).
|
|
126
126
|
|
|
127
127
|
## Agent Selection
|
|
128
128
|
|
|
@@ -213,7 +213,7 @@ Convergence expected by round 3. Hard stop at round 30.
|
|
|
213
213
|
query: "{original user query}"
|
|
214
214
|
---
|
|
215
215
|
```
|
|
216
|
-
The agent
|
|
216
|
+
The agent writes the artifact file using a file-write API that creates missing parent directories; do not run any Bash directory-creation pre-step for session outputs (R010 compliance).
|
|
217
217
|
3. GitHub issue auto-created with findings
|
|
218
218
|
4. Action items with effort estimates
|
|
219
219
|
|
package/templates/manifest.json
CHANGED