ECC/skills/continuous-learning-v2/agents
Gaurav Dubey 8b6543929e
chore(continuous-learning-v2): standardize shell shebangs to env bash (#2401)
* chore(continuous-learning-v2): standardize shell shebangs to env bash

Three scripts under skills/continuous-learning-v2/ used the hardcoded
`#!/bin/bash` shebang while the other four already used the portable
`#!/usr/bin/env bash`:

- hooks/observe.sh (runs on every hook invocation)
- scripts/detect-project.sh
- agents/start-observer.sh

The hardcoded interpreter path fails to execute on systems where bash is
not installed at /bin/bash (NixOS, some Homebrew layouts, FreeBSD).
Standardize all three to `#!/usr/bin/env bash`, matching the repo-wide
majority convention, and add a regression test that asserts shebang
uniformity for every shell script in this skill so the inconsistency
cannot reappear.

Fixes #2303

* test(continuous-learning-v2): harden shebang test runner

Address review feedback on the shebang-consistency regression test:

- firstLine() now splits on /\r?\n/ so a script checked out with CRLF
  line endings does not leave a trailing carriage return that would
  break the shebang comparison on Windows.
- The test() helper now surfaces the full error (stack trace, not just
  the message) on failure and writes pass/fail lines via
  process.stdout/stderr so diagnostics are preserved.

* test(continuous-learning-v2): skip hidden dirs in shebang scan

The recursive shell-script scan now skips hidden directories (e.g. the
observer's runtime `.observer-tmp`). This keeps the shebang-consistency
check deterministic: only committed skill scripts are examined, and an
untracked local artifact left over from an observer run can no longer
cause a false failure.
2026-07-03 20:40:44 -07:00
..
observer-loop.sh feat(continuous-learning-v2): make observer model configurable via ECC_OBSERVER_MODEL (#2390) 2026-06-29 18:43:42 -07:00
observer.md docs(continuous-learning-v2): observer.md promotion uses avg confidence, not per-instance (#2411) 2026-07-03 20:37:03 -07:00
session-guardian.sh feat: active hours + idle detection gates for session-guardian (#413) 2026-03-12 23:44:34 -07:00
start-observer.sh chore(continuous-learning-v2): standardize shell shebangs to env bash (#2401) 2026-07-03 20:40:44 -07:00