Repository navigation
feat(install): airc skills auto-install into Codex too (same SKILL.md format) - #364
Merged
Merged
Conversation
…format)
Joel installed Codex on the test rig — first non-Claude-Code agent to
hit the QA pass. Investigation: Codex CLI uses ~/.codex/skills/<name>/
SKILL.md with YAML frontmatter + markdown body — IDENTICAL on-disk
format to Claude Code's ~/.claude/skills/. Pre-fix, install.sh only
symlinked into ~/.claude/skills, so Codex sessions had no airc surface
even with Codex installed.
install.sh: extract the skill-install loop into _install_airc_skills_into
(target_dir, agent_label) and call it twice:
1. Always for $SKILLS_TARGET (Claude Code; pre-existing behavior).
2. Conditionally for $HOME/.codex/skills when both `command -v codex`
succeeds AND ~/.codex exists (i.e. Codex has been run at least
once and created its config dir). Honors CODEX_SKILLS_TARGET env
var the same way SKILLS_TARGET supports overrides for tests.
Output now distinguishes per-agent:
-> Skill (claude-code): /join
-> Skill (codex): /join
uninstall.sh: matching cleanup walks BOTH skill dirs and removes any
symlink resolving into the airc clone. Doesn't touch .system/ dirs or
non-airc symlinks (resolve target check protects against accidentally
nuking other plugins). Help block updated.
integrations/openai-codex/README.md: full refresh.
- Stale 'gh-rooted IRC over Tailscale' wording dropped (post-3c the
gist IS the wire; no Tailscale).
- Stale 'airc teardown --flush && airc join <gist-id>' recovery hint
dropped — post-#344 auth failures point at gh auth login directly.
- Adds Codex skill auto-install detail + visibility into the new
per-agent install output.
- Adds the full verb surface (whois, away, kick, identity, uninstall,
update, daemon) which the prior README only listed a subset of.
- Surfaces known gaps (Claude-Code-specific bits in skill text → #357,
DM E2EE silent-plaintext → #358) so Codex agents reading the doc
know what NOT to trust yet.
Tested on this Mac: live install run produced 23 skill symlinks under
~/.codex/skills, all resolving to ~/.airc-src/skills/<name>/. Codex
should now expose the same /join /msg /list etc. surface that Claude
Code does.
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
… sandbox flag needed)
Joel hit this on the QA rig: Codex's default sandbox blocks subcommand
network egress, so every airc verb invoked from inside Codex fails
with `error connecting to github.com` (or, because gh's auth probe
also fails, the indirect `token in keyring is invalid` misreport).
Telling users to relaunch Codex with `--sandbox danger-full-access`
or wire up `--ask-for-approval on-request` is the friction Joel called
out. Skills can't declare required permissions in Codex's current
skill format, so the cleanest automation is to write a scoped network-
permission profile into ~/.codex/config.toml at install time.
install.sh, when it detects Codex (same probe as the skill-symlink
path: `command -v codex && [ -d ~/.codex ]`), now appends a named
permission profile scoped to ONLY the gh hosts airc uses:
[permissions.airc.network]
enabled = true
mode = "limited"
domains = { "github.com" = "allow", "api.github.com" = "allow",
"gist.github.com" = "allow" }
…and sets `default_permissions = "airc"` at the file's top level,
but ONLY if no default is currently set. A user with a different
default keeps it; install.sh prints how to invoke airc-needing
sessions explicitly via `codex --profile airc`.
Idempotent: grep guards check for existing `[permissions.airc.network]`
header + `default_permissions =` line before writing. Re-runs of
install.sh on a configured machine produce no changes (no spurious
"Added airc network profile" line).
Honors AIRC_SKIP_CODEX_CONFIG=1 for users (or test harnesses) who
want the skill symlinks but NOT the config write — same shape as
AIRC_SKIP_PREREQS=1 for the package install loop.
Tested on this Mac: first run added both blocks (top-level key +
[permissions.airc.network] section). Second run was a no-op (no
output line, no file change). Verified: cat ~/.codex/config.toml
shows the profile + matches Codex's documented format.
Doesn't use the codex CLI for the write because there is no `codex
config` subcommand — Codex offers per-invocation `-c key=value`
overrides + named profile loading via `-p`, but no persistent-edit
CLI. File-edit + grep idempotency is the standard pattern install.sh
already uses for shellrc PATH addition.
README updated to document the auto-config + the AIRC_SKIP_CODEX_CONFIG
escape hatch.
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…ock (silences Codex warning) Joel's Codex first-encounter QA surfaced the warning: Permissions profile 'airc' does not define any recognized filesystem entries for this version of Codex. Filesystem access will remain restricted. The original [permissions.airc.network] block (added in 867c161) granted network access to gh's domains but left filesystem entries empty. Codex's default-restricted filesystem then silently blocks airc verbs that mutate state (identity bootstrap, airc update, the per-cwd state writes), even though the user thought the airc profile was the default. Adds a paired [permissions.airc.filesystem] block scoped to airc's actual footprint: ~/.airc-src/ airc clone + .venv (airc update, identity bootstrap) ~/.airc/ user-default state dir ~/.local/bin/airc + relay binary symlinks (write needed for uninstall) Plus a [permissions.airc.filesystem.':project_roots'] sub-section for the per-cwd .airc/ + .airc.general/ directories (per-project airc state + #general sidecar). Codex's TOML syntax for filesystem permissions per the config reference: permissions.<name>.filesystem.<path-or-glob> = "read" | "write" | "none" :project_roots is the special token for per-project scoping. Idempotent: grep guard checks for existing [permissions.airc.filesystem] header before writing. Same shape as the network block. Tested on this Mac: live install.sh re-run wrote the new block once, second run was a no-op (no spurious changes), config.toml has both [permissions.airc.network] and [permissions.airc.filesystem] sections with the airc.filesystem.':project_roots' sub-section. Codex first-encounter (Joel's QA tab) should pick this up on next restart and the filesystem warning should clear. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
4 of 5 tasks
joelteply
added a commit
that referenced
this pull request
Apr 30, 2026
…startup (regression from #364) (#366) The filesystem-permission block added in the second commit of #364 broke Codex on startup with: Error loading configuration: permissions profile requests filesystem writes outside the workspace root, which is not supported until the runtime enforces FileSystemSandboxPolicy directly Codex 0.125's runtime can't honor home-dir-scoped filesystem grants in named profiles yet. Even the :project_roots-only variant didn't help (the block was rejected as a whole). On every machine that ran the merged #364, the next codex invocation fails to start until the block is removed from ~/.codex/config.toml manually. Surfaced live during the codex first-encounter QA: after Joel restarted Codex post-#364 merge, Codex hard-failed at config load with the above error. Two-part hotfix: 1. Stop writing the [permissions.airc.filesystem] block. Replace the write code with a comment explaining why the block is omitted and pointing at git history for the prior version. Living with Codex's harmless 'does not define any recognized filesystem entries' warning is preferable to a hard-fail-on-startup that takes Codex offline entirely. 2. Add a cleanup step that DETECTS the broken block in existing ~/.codex/config.toml files and strips it. Without this, every user who already ran #364 has a permanently broken Codex until they hand-edit. Cleanup uses Python with the existing venv (we have it from cryptography) to do a section-aware strip; handles the leading '# airc filesystem permissions' comment and any [permissions.airc.filesystem.<sub>] children in one pass. Runs every install.sh invocation; idempotent (no-op when the block is already absent). Collapses runs of >2 blank lines that the strip might have left. Tested on this Mac: - simulated stale block → install.sh detects + strips - Codex (codex exec) starts cleanly after cleanup - re-runs of install.sh on cleaned config: no-op, no spurious changes Network profile + skill symlinks from #364 stay intact and continue working — only the filesystem block is removed. Open question / followup: Codex's docs claim filesystem profiles are supported per the config-reference, but the runtime rejects them. Possibly a 0.125-vs-newer-version gap. When/if Codex's runtime adds support, restore the block (history at git log -- install.sh). Co-authored-by: joel <[email protected]> Co-authored-by: Claude Opus 4.7 (1M context) <[email protected]>
This was referenced Apr 30, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Joel installed Codex on the test rig — first non-Claude-Code agent in this QA pass — and the existing integration was doc-only with stale Tailscale references. Investigation: Codex CLI uses
~/.codex/skills/<name>/SKILL.mdwith identical on-disk format to Claude Code's~/.claude/skills/. Pre-fix, install.sh only symlinked into ~/.claude/skills, so Codex sessions had no airc surface even with Codex installed.Change
install.sh: extract the skill-install loop into
_install_airc_skills_into(target_dir, agent_label)and call it twice:$SKILLS_TARGET(Claude Code; pre-existing behavior unchanged).$HOME/.codex/skillswhencommand -v codexAND~/.codexexists (Codex installed + initialized). HonorsCODEX_SKILLS_TARGETenv var for tests.Output now distinguishes per-agent:
uninstall.sh: matching cleanup walks both skill dirs and removes symlinks resolving into the airc clone. Resolve-target check protects against nuking unrelated plugins.
integrations/openai-codex/README.md: full refresh.
airc teardown --flush && airc join <gist-id>recovery hint — post-fix(gh): distinguish secondary rate limit from auth failure + skill scope-doc correction (#341) #344 auth failures point atgh auth logindirectly.Tested on this Mac
Live install run produced 23 skill symlinks under
~/.codex/skills/, all resolving to~/.airc-src/skills/<name>/. Codex should now expose the same /join /msg /list etc. surface that Claude Code does.Test plan
airc update(or install.sh) backfills the Codex symlinksKnown caveats noted in the README
🤖 Generated with Claude Code