The ci-workflow helper emits an invalid GITHUB_ENV trailer for MEGAREPO_STORE (and similarly MEGAREPO_SKIP_MEMBERS).
In genie/ci-workflow.ts around line 1149:
printf 'MEGAREPO_STORE=%s\n' "\$MEGAREPO_STORE" >> "\$GITHUB_ENV"
Because the script is embedded in a multi-line TS template literal and ultimately rendered into a YAML run: block, the \n in the JS source becomes an actual newline inside the printf format string. The rendered YAML then looks like:
printf 'MEGAREPO_STORE=%s
' "$MEGAREPO_STORE" >> "$GITHUB_ENV"
printf therefore writes MEGAREPO_STORE=<value>\n to \$GITHUB_ENV — a valid directive followed by an indentation-only line. GitHub Actions parses each non-empty line in \$GITHUB_ENV as an env directive; a whitespace-only trailer can cause Invalid format failures under stricter parsing or when the trailing spaces are preserved by a runner.
Fix
Use either:
- an unambiguous single-line assignment:
echo "MEGAREPO_STORE=\$MEGAREPO_STORE" >> "\$GITHUB_ENV" (matches the pattern used elsewhere in the same file, e.g. `PNPM_STORE_DIR`), or
- escape the newline so printf — not JS — expands it:
printf 'MEGAREPO_STORE=%s\\n' ...
The same pattern applies to the MEGAREPO_SKIP_MEMBERS printf a few lines below.
Context
Flagged by a Codex review on schickling/dotfiles PR #621 (Forge Electron work). CI there is currently green, so the issue is latent in that workflow, but worth fixing upstream to keep \$GITHUB_ENV strictly well-formed.
Posted on behalf of @schickling
agent_name: 💨 cl2-mist
agent_session_id: 51498441-542a-4ec3-b486-db9bbde795c0
agent_tool: Claude Code
agent_tool_version: 2.1.118 (Claude Code)
agent_runtime: Claude Code 2.1.118 (Claude Code)
agent_model: unknown
worktree: dotfiles/schickling/2026-04-10-forge-electron
machine: mbp2025
The ci-workflow helper emits an invalid GITHUB_ENV trailer for
MEGAREPO_STORE(and similarlyMEGAREPO_SKIP_MEMBERS).In
genie/ci-workflow.tsaround line 1149:Because the script is embedded in a multi-line TS template literal and ultimately rendered into a YAML
run:block, the\nin the JS source becomes an actual newline inside the printf format string. The rendered YAML then looks like:printf therefore writes
MEGAREPO_STORE=<value>\nto\$GITHUB_ENV— a valid directive followed by an indentation-only line. GitHub Actions parses each non-empty line in\$GITHUB_ENVas an env directive; a whitespace-only trailer can causeInvalid formatfailures under stricter parsing or when the trailing spaces are preserved by a runner.Fix
Use either:
echo "MEGAREPO_STORE=\$MEGAREPO_STORE" >> "\$GITHUB_ENV"(matches the pattern used elsewhere in the same file, e.g. `PNPM_STORE_DIR`), orprintf 'MEGAREPO_STORE=%s\\n' ...The same pattern applies to the
MEGAREPO_SKIP_MEMBERSprintf a few lines below.Context
Flagged by a Codex review on schickling/dotfiles PR #621 (Forge Electron work). CI there is currently green, so the issue is latent in that workflow, but worth fixing upstream to keep
\$GITHUB_ENVstrictly well-formed.Posted on behalf of @schickling
agent_name: 💨 cl2-mistagent_session_id: 51498441-542a-4ec3-b486-db9bbde795c0agent_tool: Claude Codeagent_tool_version: 2.1.118 (Claude Code)agent_runtime: Claude Code 2.1.118 (Claude Code)agent_model: unknownworktree: dotfiles/schickling/2026-04-10-forge-electronmachine: mbp2025