Introduces a new job type for long-running systemd user services alongside
the existing timer-based jobs. Services use Type=simple with Restart=on-failure
and WantedBy=default.target — no .timer unit is created.
- New -s flag creates a service job; mutually exclusive with -t/-i/-m/-o
- Service jobs tagged with # SYSTAB_TYPE=service in their unit file
- enable/disable (-E/-D) start/stop the service in addition to toggling
the enabled state, mirroring timer behaviour
- -S status shows ActiveState/SubState from systemd directly (avoids
false "Inactive" for services in activating state)
- -L logs, -e edit mode, -D/-E disable/enable all handle service jobs
- Edit mode represents service jobs with 'service' as the schedule column
(e.g. new:s,n=name | service | /path/to/cmd)
- daemon-reload runs before enable/start during service creation so
systemd registers the new unit file first
- 22 new tests covering unit file contents, active state, disable/enable,
named services, edit mode representation, and flag conflict errors
- New demo/services.tape and regenerated demo GIFs
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Test cleanup now only removes jobs it created (tracked via
test_job_ids array) instead of nuking all systab_* units.
Fixes bug where running tests would delete real user jobs.
- Fix extract_id subshell issue: array appends in $() don't
propagate to parent, so use _extracted_id variable instead.
- Merge disable_job_by_id/enable_job_by_id into toggle_job_by_id.
- Update usage text: -D/-E/-L/-S now show <id|name> consistently.
- Fix pre-commit hook sed regex that only captured last digit of
multi-digit numbers; replaced with grep -oP.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
44 tests covering job creation, status, logs, pause/resume,
notifications, time format parsing, error cases, and cleanup.
Tests run against real systemd user timers with automatic cleanup.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>