oh-my-customcodex 0.2.0 → 0.2.1

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
@@ -225,7 +225,7 @@ Key rules: R010 (orchestrator never writes files), R009 (parallel execution mand
225
225
 
226
226
  ---
227
227
 
228
- ### Guides (39)
228
+ ### Guides (40)
229
229
 
230
230
  Reference documentation covering best practices, architecture decisions, and integration patterns. Located in `guides/` at project root, covering topics from agent design to CI/CD to observability.
231
231
 
@@ -282,7 +282,11 @@ your-project/
282
282
  │ ├── specs/ # Extracted canonical specs
283
283
  │ ├── contexts/ # 4 shared context files
284
284
  │ └── ontology/ # Knowledge graph for RAG
285
- └── guides/ # 39 reference documents
285
+ <<<<<<< HEAD
286
+ └── guides/ # 40 reference documents
287
+ =======
288
+ └── guides/ # 40 reference documents
289
+ >>>>>>> origin/develop
286
290
  ```
287
291
 
288
292
  ---
package/dist/cli/index.js CHANGED
@@ -3087,7 +3087,7 @@ var init_package = __esm(() => {
3087
3087
  workspaces: [
3088
3088
  "packages/*"
3089
3089
  ],
3090
- version: "0.2.0",
3090
+ version: "0.2.1",
3091
3091
  description: "Batteries-included agent harness on top of GPT Codex + OMX",
3092
3092
  type: "module",
3093
3093
  bin: {
package/dist/index.js CHANGED
@@ -2173,7 +2173,7 @@ var package_default = {
2173
2173
  workspaces: [
2174
2174
  "packages/*"
2175
2175
  ],
2176
- version: "0.2.0",
2176
+ version: "0.2.1",
2177
2177
  description: "Batteries-included agent harness on top of GPT Codex + OMX",
2178
2178
  type: "module",
2179
2179
  bin: {
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "workspaces": [
4
4
  "packages/*"
5
5
  ],
6
- "version": "0.2.0",
6
+ "version": "0.2.1",
7
7
  "description": "Batteries-included agent harness on top of GPT Codex + OMX",
8
8
  "type": "module",
9
9
  "bin": {
@@ -105,6 +105,10 @@
105
105
  {
106
106
  "matcher": "tool == \"Task\" || tool == \"Agent\"",
107
107
  "hooks": [
108
+ {
109
+ "type": "command",
110
+ "command": "bash .codex/hooks/scripts/agent-mode-guard.sh"
111
+ },
108
112
  {
109
113
  "type": "command",
110
114
  "command": "#!/bin/bash\ninput=$(cat)\nagent_type=$(echo \"$input\" | jq -r '.tool_input.subagent_type // \"unknown\"')\nmodel=$(echo \"$input\" | jq -r '.tool_input.model // \"inherit\"')\ndesc=$(echo \"$input\" | jq -r '.tool_input.description // \"\"' | head -c 40)\nresume=$(echo \"$input\" | jq -r '.tool_input.resume // empty')\nif [ -n \"$resume\" ]; then\n echo \"─── [Resume] ${agent_type}:${model} | ${desc} ───\" >&2\nelse\n echo \"─── [Spawn] ${agent_type}:${model} | ${desc} ───\" >&2\nfi\necho \"$input\""
@@ -0,0 +1,22 @@
1
+ #!/bin/bash
2
+ # Agent mode guard
3
+ # Blocks Agent/Task spawns that omit mode:"bypassPermissions".
4
+ # This closes the gap where frontmatter permissionMode is ignored unless the
5
+ # spawn call sets mode explicitly.
6
+
7
+ set -euo pipefail
8
+
9
+ command -v jq >/dev/null 2>&1 || exit 0
10
+
11
+ input=$(cat)
12
+ mode=$(echo "$input" | jq -r '.tool_input.mode // ""')
13
+
14
+ if [ "$mode" != "bypassPermissions" ]; then
15
+ echo "[Hook] BLOCKED: Agent/Task spawn missing required mode: \"bypassPermissions\"" >&2
16
+ echo "[Hook] Saw mode: ${mode:-<missing>}" >&2
17
+ echo "[Hook] The Agent tool defaults to acceptEdits and will trigger permission prompts." >&2
18
+ echo "[Hook] Fix the spawn call by adding: mode: \"bypassPermissions\"" >&2
19
+ exit 2
20
+ fi
21
+
22
+ echo "$input"
@@ -119,7 +119,7 @@ project/
119
119
  | +-- rules/ # 전역 규칙 (R000-R022)
120
120
  | +-- hooks/ # 훅 스크립트 (보안, 검증, HUD)
121
121
  | +-- contexts/ # 컨텍스트 파일 (ecomode)
122
- +-- guides/ # 레퍼런스 문서 (38 토픽)
122
+ +-- guides/ # 레퍼런스 문서 (39 토픽)
123
123
  ```
124
124
 
125
125
  ## 오케스트레이션
@@ -136,7 +136,7 @@ project/
136
136
  | +-- rules/ # Global rules (22 files)
137
137
  | +-- hooks/ # Hook scripts (security, validation, HUD)
138
138
  | +-- contexts/ # Context files (4 files)
139
- +-- guides/ # Reference docs (38 topics)
139
+ +-- guides/ # Reference docs (39 topics)
140
140
  ```
141
141
 
142
142
  ## Orchestration
@@ -136,7 +136,7 @@ project/
136
136
  | +-- rules/ # 전역 규칙 (22 파일)
137
137
  | +-- hooks/ # 훅 스크립트 (보안, 검증, HUD)
138
138
  | +-- contexts/ # 컨텍스트 파일 (4 파일)
139
- +-- guides/ # 레퍼런스 문서 (38 토픽)
139
+ +-- guides/ # 레퍼런스 문서 (39 토픽)
140
140
  ```
141
141
 
142
142
  ## 오케스트레이션
@@ -57,6 +57,14 @@ guides:
57
57
  origin: docs.oracle.com
58
58
  url: https://docs.oracle.com/en/java/javase/21/
59
59
 
60
+ - name: java
61
+ description: Java 25 LTS language reference and modern feature documentation
62
+ path: ./java/
63
+ source:
64
+ type: external
65
+ origin: docs.oracle.com
66
+ url: https://docs.oracle.com/en/java/javase/25/
67
+
60
68
  - name: python
61
69
  description: Python reference from PEP 8 and PEP 20
62
70
  path: ./python/
@@ -0,0 +1,29 @@
1
+ # Java Guide
2
+
3
+ metadata:
4
+ name: java
5
+ description: Java 25 LTS language reference and modern feature documentation
6
+
7
+ source:
8
+ type: external
9
+ origin: docs.oracle.com
10
+ urls:
11
+ - https://docs.oracle.com/en/java/javase/25/
12
+ - https://openjdk.org/projects/loom/
13
+ - https://openjdk.org/jeps/440
14
+ - https://openjdk.org/jeps/441
15
+ - https://openjdk.org/jeps/444
16
+ - https://google.github.io/styleguide/javaguide.html
17
+ last_fetched: "2026-04-20"
18
+
19
+ documents:
20
+ - name: modern-java
21
+ path: ./modern-java.md
22
+ description: Java 25 LTS modern features (Virtual Threads, Pattern Matching, Records, Sealed Classes)
23
+
24
+ - name: java-style-guide
25
+ path: ./java-style-guide.md
26
+ description: Google Java Style Guide conventions
27
+
28
+ used_by:
29
+ - lang-java-expert
@@ -0,0 +1,35 @@
1
+ # Google Java Style Guide Notes
2
+
3
+ > Source: https://google.github.io/styleguide/javaguide.html
4
+
5
+ ## Core Conventions
6
+
7
+ - Indent with 2 spaces, never tabs
8
+ - Use `UpperCamelCase` for classes, `lowerCamelCase` for methods and fields
9
+ - Constants use `UPPER_SNAKE_CASE`
10
+ - Prefer one top-level type per file
11
+ - Keep line length readable and wrap before expressions become visually dense
12
+
13
+ ## Imports
14
+
15
+ - No wildcard imports
16
+ - Static imports come before non-static imports
17
+ - Keep imports sorted ASCII-style within each block
18
+
19
+ ## Braces
20
+
21
+ - Opening brace stays on the same line
22
+ - Always use braces for `if`, `for`, `while`, and `do`
23
+
24
+ ## Classes And Members
25
+
26
+ - Order members consistently: constants, fields, constructors, public methods, private helpers
27
+ - Prefer immutable fields where possible
28
+ - Document non-obvious public API behavior with Javadoc
29
+
30
+ ## Naming
31
+
32
+ - Packages: lowercase, no underscores
33
+ - Types: nouns or noun phrases
34
+ - Methods: verbs or verb phrases
35
+ - Test methods: describe behavior, not implementation detail
@@ -0,0 +1,71 @@
1
+ # Modern Java Features
2
+
3
+ > Sources: https://openjdk.org/jeps/ (JEP 431, 440, 441, 444)
4
+
5
+ ## Virtual Threads (JEP 444)
6
+
7
+ Virtual Threads are lightweight threads managed by the JVM, enabling millions of concurrent tasks without thread pool tuning.
8
+
9
+ ### Key Properties
10
+
11
+ | Property | Platform Thread | Virtual Thread |
12
+ |----------|----------------|----------------|
13
+ | Creation cost | High (OS thread) | Low (JVM-managed) |
14
+ | Memory footprint | ~1MB per thread | ~few KB |
15
+ | Blocking behavior | Blocks OS thread | Unmounts carrier thread |
16
+ | Pooling | Needed | Not recommended |
17
+
18
+ ### Usage
19
+
20
+ ```java
21
+ try (var executor = Executors.newVirtualThreadPerTaskExecutor()) {
22
+ List<Future<String>> futures = IntStream.range(0, 10_000)
23
+ .mapToObj(i -> executor.submit(() -> fetchData(i)))
24
+ .toList();
25
+ }
26
+
27
+ Thread.ofVirtual().name("vt-worker").start(() -> processRequest());
28
+ ```
29
+
30
+ ## Pattern Matching
31
+
32
+ ```java
33
+ if (obj instanceof String s && !s.isEmpty()) {
34
+ return s.toUpperCase();
35
+ }
36
+
37
+ String format = switch (obj) {
38
+ case Integer i -> "int %d".formatted(i);
39
+ case String s -> "string %s".formatted(s);
40
+ case null -> "null";
41
+ default -> obj.toString();
42
+ };
43
+ ```
44
+
45
+ ## Records
46
+
47
+ ```java
48
+ record Point(int x, int y) {}
49
+
50
+ record Range(int min, int max) {
51
+ Range {
52
+ if (min > max) {
53
+ throw new IllegalArgumentException("min > max");
54
+ }
55
+ }
56
+ }
57
+ ```
58
+
59
+ ## Sealed Types
60
+
61
+ ```java
62
+ sealed interface Shape permits Circle, Rectangle {}
63
+
64
+ record Circle(double radius) implements Shape {}
65
+ record Rectangle(double width, double height) implements Shape {}
66
+ ```
67
+
68
+ ## Sequenced Collections
69
+
70
+ - Prefer `getFirst()` / `getLast()` over index arithmetic for ordered collections
71
+ - Use `reversed()` when reverse traversal is the intent
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "0.2.0",
2
+ "version": "0.2.1",
3
3
  "lastUpdated": "2026-04-19T08:50:00.000Z",
4
4
  "components": [
5
5
  {
@@ -24,7 +24,7 @@
24
24
  "name": "guides",
25
25
  "path": "guides",
26
26
  "description": "Reference documentation",
27
- "files": 39
27
+ "files": 40
28
28
  },
29
29
  {
30
30
  "name": "hooks",