Run a session overnight
Put a long session on the watch, so a timer nudges it when it goes idle and alerts you when it needs you.
Use this guide when a session must keep working while nobody watches it, for example overnight. The watcher nudges the session when it goes idle with work left, asks it for a handoff when its context grows large, and alerts you once when only you can go on. The watcher explains what one pass does and why it is safe to leave running.
Before you start
- The session runs in an
hcterminal (herdr). The watcher reads and nudges sessions throughhc. - Linux with systemd user timers.
- The program has its go and its defaults. See Run large work as a program.
Steps
-
Install the timer once. From the practice clone:
cd ~/Code/komputa-practice watcher/watcherctl install # a dry run: it prints what it would write watcher/watcherctl install --apply # writes practice-watch.service and .timer watcher/watcherctl enable # a pass every 5 minutes, now and after each login -
Put the session on the watch. Run this from inside the session’s own
hcterminal, or name the terminal:~/Code/komputa-practice/watcher/practice-watch on # or: ... on t7 ~/Code/komputa-practice/watcher/practice-watch status # what is watched -
Leave it. Each pass reads every terminal labelled
watch=on. A session that has gone idle with work left gets one nudge. A session that is blocked, out of nudges or ended raises one alert. -
In the morning, take it off the watch:
~/Code/komputa-practice/watcher/practice-watch off
Check it worked
watcher/watcherctl status
It shows the timer, its last passes and the watched sessions.
Stop or remove it
watcher/watcherctl disable # stops the timer
watcher/watcherctl uninstall --apply # removes the service and the timer
Next steps
- The watcher: what one pass does, its settings, and why it never types over you.
- Run large work as a program: plans, handoffs and the go.