Summary
Port scripts/start-services.sh (213 lines) to src/lib/services.ts as part of the #924 shell consolidation.
This script manages PID files and starts helper services (cloudflared tunnel, port forwarding) for nemoclaw start. Currently implemented as bash that bin/nemoclaw.js shells out to.
Approach
- Write
src/lib/services.ts using execa for subprocess execution
- Replace the shell-out in
bin/nemoclaw.js with a direct call to the TS module
- PID file management must be preserved (start/stop/status lifecycle)
- Follow the established pattern: TS source in
src/lib/, compiled to dist/lib/ via npm run build:cli
- Co-locate tests in
src/lib/services.test.ts, importing from ../../dist/lib/services for coverage attribution
Context
Not blocked by
Any of the #924 blocker PRs (#781, #782, #819, #672, #794, #634).
Summary
Port
scripts/start-services.sh(213 lines) tosrc/lib/services.tsas part of the #924 shell consolidation.This script manages PID files and starts helper services (cloudflared tunnel, port forwarding) for
nemoclaw start. Currently implemented as bash thatbin/nemoclaw.jsshells out to.Approach
src/lib/services.tsusing execa for subprocess executionbin/nemoclaw.jswith a direct call to the TS modulesrc/lib/, compiled todist/lib/vianpm run build:clisrc/lib/services.test.ts, importing from../../dist/lib/servicesfor coverage attributionContext
Not blocked by
Any of the #924 blocker PRs (#781, #782, #819, #672, #794, #634).