feat(phase5): polish + deployment

- skill/SKILL.md: rewritten to 9 lines — 'status is automatic'
- deploy-to-agents.sh: no AGENTS.md injection; deploys hook + npm install
- install.sh: clean install flow; prints required env vars
- deploy/status-watcher.service: systemd unit file
- deploy/Dockerfile: containerized deployment (node:22-alpine)
- src/live-status.js: deprecation warning + start-watcher/stop-watcher pass-through
- README.md: full docs (architecture, install, config, upgrade guide, troubleshooting)
- make check: 0 errors, 0 format issues
- npm test: 59 unit + 36 integration = 95 tests passing
This commit is contained in:
sol
2026-03-07 17:45:22 +00:00
parent 5bb36150c4
commit 835faa0eab
7 changed files with 476 additions and 160 deletions

View File

@@ -7,6 +7,14 @@ const http = require('http');
const fs = require('fs');
const path = require('path');
// --- DEPRECATION WARNING ---
// In v4, live-status CLI is deprecated. The status-watcher daemon handles
// all updates automatically by tailing JSONL transcripts. You do not need
// to call this tool manually. It remains available for backward compatibility.
if (process.stderr.isTTY) {
console.error('NOTE: live-status CLI is deprecated as of v4. Status updates are now automatic.');
}
// --- PARSE ARGS ---
const args = process.argv.slice(2);
let command = null;
@@ -33,7 +41,12 @@ for (let i = 0; i < args.length; i++) {
i++;
} else if (arg === '--rich') {
options.rich = true;
} else if (!command && ['create', 'update', 'complete', 'error', 'delete'].includes(arg)) {
} else if (
!command &&
['create', 'update', 'complete', 'error', 'delete', 'start-watcher', 'stop-watcher'].includes(
arg,
)
) {
command = arg;
} else {
otherArgs.push(arg);
@@ -294,7 +307,17 @@ async function deletePost(postId) {
}
// --- CLI ROUTER ---
if (command === 'create') {
if (command === 'start-watcher' || command === 'stop-watcher') {
// Pass-through to watcher-manager.js
const { spawnSync } = require('child_process');
const watcherPath = path.join(__dirname, 'watcher-manager.js');
const subCmd = command === 'start-watcher' ? 'start' : 'stop';
const result = spawnSync(process.execPath, [watcherPath, subCmd], {
stdio: 'inherit',
env: process.env,
});
process.exit(result.status || 0);
} else if (command === 'create') {
createPost(otherArgs.join(' '), 'create');
} else if (command === 'update') {
updatePost(otherArgs[0], otherArgs.slice(1).join(' '), 'update');
@@ -311,6 +334,8 @@ if (command === 'create') {
console.log(' live-status [options] complete <id> <text>');
console.log(' live-status [options] error <id> <text>');
console.log(' live-status [options] delete <id>');
console.log(' live-status start-watcher (pass-through to watcher-manager start)');
console.log(' live-status stop-watcher (pass-through to watcher-manager stop)');
console.log('');
console.log('Options:');
console.log(' --rich Use rich message attachments (colored cards)');