vintlin/computer-care-skills/processes-monitor

Claude Code and agent skill by vintlin/computer-care-skills

Trust tier 3
  • community
Source check pending

Checking that the SKILL.md file is still in the repository.

Use when monitoring long-running local commands with heartbeat liveness checks — background jobs, builds, scripts, services, downloads, or batch automation that may hang, timeout, crash, or lose logs.

Install

npx vskill@latest install vintlin/computer-care-skills/processes-monitor

SKILL.md

Processes Monitor

Overview

Monitor long-running work with explicit status files, heartbeats, logs, and timeouts. A PID alone proves a process exists; it does not prove progress.

Sentinel Pattern

Create a monitor directory with:

FilePurpose
<name>.pidProcess ID
<name>.heartbeatUpdated periodically while work progresses
<name>.statusSUCCESS, FAILED, TIMEOUT, or HUNG
<name>.logCaptured stdout/stderr
<name>.resultOptional structured output

Minimal Wrapper

bash
#!/usr/bin/env bash
set -uo pipefail
name="${1:?name required}"
monitor_dir="${2:-/tmp/process-monitor}"
mkdir -p "$monitor_dir"
echo $$ > "$monitor_dir/$name.pid"
(while true; do touch "$monitor_dir/$name.heartbeat"; sleep 10; done) &
heartbeat_pid=$!
trap 'kill "$heartbeat_pid" 2>/dev/null' EXIT
if your_command >"$monitor_dir/$name.log" 2>&1; then
echo SUCCESS > "$monitor_dir/$name.status"
else
echo FAILED > "$monitor_dir/$name.status"
fi

Always write a final status — never leave monitor files in an ambiguous state. The trap ensures the heartbeat loop is cleaned up on exit.

Monitor Logic

Check in a loop:

  1. If .status exists, read it and stop.
  2. If .heartbeat is stale beyond the threshold, treat as hung. Do not kill a process only because it is slow — compare heartbeat age, log output, and elapsed time before deciding.
  3. If elapsed time exceeds the timeout, stop or escalate. Do not restart a failing process repeatedly without reading its log first.
  4. Otherwise wait and check again. Avoid tail -f | grep -m1 for log watching — it can hang on macOS due to buffering. Prefer polling the status file.

Recommended defaults:

SettingValue
heartbeat interval10 seconds
stale threshold60 seconds
poll interval10-15 seconds
max timeoutbased on task, declared before start

Security

  • Security scanPassed, 95 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

7-day trend score
0

Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/vintlin/computer-care-skills/processes-monitor/badge)](https://verified-skill.com/skills/vintlin/computer-care-skills/processes-monitor)

Something wrong with this skill or its page? Tell us.