chore: add codex environment
CI / validate (push) Successful in 35s

This commit is contained in:
2026-07-21 11:13:54 -05:00
parent b445d8a117
commit 084f76d3c1
6 changed files with 51 additions and 1 deletions
+41
View File
@@ -0,0 +1,41 @@
# THIS IS AUTOGENERATED. DO NOT EDIT MANUALLY
version = 1
name = "mp-ai-module-controller"
[setup]
script = "scripts/codex-setup.sh"
[[actions]]
name = "Build"
icon = "tool"
command = "cargo build"
[[actions]]
name = "Test"
icon = "tool"
command = "cargo test"
[[actions]]
name = "Generate Dictionary"
icon = "tool"
command = "cargo run -- dictionary generate"
[[actions]]
name = "Precommit Check"
icon = "tool"
command = "scripts/precommit-check.sh"
[[actions]]
name = "Run Logger"
icon = "run"
command = "cargo run -- run logger --payload '{\"message\":\"hello from codex environment\"}'"
[[actions]]
name = "Query Logger"
icon = "run"
command = "cargo run -- query \"log hello from codex\""
[[actions]]
name = "Serve Llama"
icon = "run"
command = "cargo run -- serve"
+1
View File
@@ -7,3 +7,4 @@
/dictionary/actions.jsonl
/dictionary/actions.index.json
*.log
.DS_Store
+2
View File
@@ -15,6 +15,7 @@
- Codex setup: `scripts/codex-setup.sh`
- Codex logger smoke test: `scripts/codex-run-logger.sh`
- Precommit/CI check: `scripts/precommit-check.sh`
- Codex environment: `.codex/environments/environment.toml`
## Environment
@@ -55,6 +56,7 @@ Use `.env` for local values and keep it out of git. Update `.env.example`, `READ
## CI And Hooks
- Codex environment actions live at `.codex/environments/environment.toml`.
- Gitea Actions workflow lives at `.gitea/workflows/ci.yml`.
- Woodpecker workflow lives at `.woodpecker.yml`.
- The committed pre-commit hook lives at `.githooks/pre-commit`.
+1
View File
@@ -63,6 +63,7 @@ The first registered script is `logger`. It writes JSONL records to `logs/contro
The project includes:
- `.codex/environments/environment.toml` for Codex setup and run actions.
- `.gitea/workflows/ci.yml` for Gitea Actions.
- `.woodpecker.yml` for Woodpecker.
- `.githooks/pre-commit` for local pre-commit checks.
+3
View File
@@ -26,6 +26,7 @@ Commands:
- `scripts/codex-run-logger.sh`
- `scripts/precommit-check.sh`
- `git config core.hooksPath .githooks`
- `.codex/environments/environment.toml`
Environment:
@@ -38,4 +39,6 @@ Environment:
The LLM must return compact JSON like `{"action_id":"logger","payload":{"message":"hello"}}`. The runtime only executes exact `action_id` matches from `dictionary/actions.index.json`; aliases are not executable. Invalid or unknown outputs are rejected without running anything.
Codex environment: `.codex/environments/environment.toml` defines setup plus Build, Test, Generate Dictionary, Precommit Check, Run Logger, Query Logger, and Serve Llama actions.
CI and hooks: `.gitea/workflows/ci.yml`, `.woodpecker.yml`, and `.githooks/pre-commit` all use `scripts/precommit-check.sh` to verify formatting, tests, and dictionary generation.
+3 -1
View File
@@ -11,7 +11,8 @@
"dictionary_generator": "src/dictionary.rs",
"llm_client": "src/llm.rs",
"dispatcher": "src/dispatcher.rs",
"logger_script": "src/scripts/logger.rs"
"logger_script": "src/scripts/logger.rs",
"codex_environment": ".codex/environments/environment.toml"
},
"commands": {
"build": "cargo build",
@@ -108,6 +109,7 @@
"dictionary/actions.index.json"
],
"ci": {
"codex_environment": ".codex/environments/environment.toml",
"gitea_actions": ".gitea/workflows/ci.yml",
"woodpecker": ".woodpecker.yml",
"precommit_hook": ".githooks/pre-commit",