4 Commits
Author SHA1 Message Date
John SmithandClaude 1858458954 Fix unclosed command substitutions in all shell scripts
All scripts using the pattern AGENT_OUTPUTS=$(cat <<OUTPUTS ... OUTPUTS
were missing the closing ')' for the  command substitution. This caused
'unexpected EOF while looking for matching )' errors at runtime.

Fixed 7 files: build-context.sh, watch-checks.sh, triage-issue.sh,
analyze-pr.sh, run-review.sh, run-release.sh, and the 3 write-envelope.sh
files (rust-ci, js-ci, python-ci).

Co-Authored-By: Claude <[email protected]>
2026-07-30 11:34:10 -04:00
John SmithandClaude 929f0a9c23 Fix CI failures: permissions, reserved secret name, pre-commit types
Three issues causing all workflow runs to fail:

1. github_token is a reserved name in workflow_call secrets
   - Renamed to repo_token across ocr-review, ocr-scan, release, and
     check-status workflows. Updated all secrets.repo_token refs.

2. Shell scripts not executable (exit code 126)
   - chmod +x all .sh files in .github/actions/

3. pre-commit types_or rejected 'typescript' type tag
   - Changed to 'ts' in .pre-commit-config.yaml for eslint and prettier hooks

Co-Authored-By: Claude <[email protected]>
2026-07-30 11:24:16 -04:00
John SmithandClaude 5523b46c62 Fix the github.action_path references in shell scripts
Shell scripts (.sh) were sourcing agent-envelope.sh via the literal
GitHub Actions expression '${{ github.action_path }}', which doesn't get
evaluated by the shell — only in run: blocks in action YAML files.

Fix: Pass AGENT_ACTION_PATH as an environment variable from the action.yml
env block (where the runner evaluates the expression) and reference it as
${AGENT_ACTION_PATH} in shell scripts.

Also fix: date format bug (%Y repeated twice) in agent-envelope.sh

Co-Authored-By: Claude <[email protected]>
2026-07-30 11:00:53 -04:00
John SmithandClaude c3633b2b14 Initial commit: Heretek Actions — agent-facing GitHub Actions
Complete implementation of all 7 phases:

Phase 1: Foundation
- Repository directory structure
- .agent/schema.json — Standard JSON envelope schema
- .github/CODEOWNERS, LICENSE (MIT), .gitignore
- README.md shell

Phase 2: Agent-Facing Actions (5 composite actions)
- agent-context — Scans repo, detects stack, queries GitHub API
- pr-summary — Analyzes PR diff, categorizes files, links issues
- issue-triage — Classifies, labels, detects duplicates
- check-status — Watches CI checks, produces merged status
- review — Lightweight structural code analysis
- Shared agent-envelope.sh helper for standardized .agent/output.json

Phase 3: Pre-commit Hooks
- .pre-commit-config.yaml — Universal hook config
- pre-commit-ci.yml — CI workflow running pre-commit

Phase 4: CI Composite Actions
- rust-ci — fmt, clippy, test, coverage (opt), audit (opt)
- js-ci — lint, typecheck, test (npm/pnpm/yarn/bun)
- python-ci — lint (ruff), typecheck (mypy), test (pytest)

Phase 5: Universal CI Orchestrator
- check.yml — Auto-detects languages, routes to CI actions

Phase 6: Universal Release
- release action — Docker, Flatpak, npm, GitHub releases
- release.yml — workflow_call reusable workflow

Phase 7: Documentation
- Full README with quick start, per-action docs, agent integration guide

Co-Authored-By: Claude <[email protected]>
2026-07-30 10:58:06 -04:00