pi-heartbeat
Configure periodic health checks via HEARTBEAT.md and the /heartbeat command.
Monitor open GitHub PRs across all repos in ~/Dev. Checks PR age, flags stale PRs, and optionally alerts via Aivena/Telegram. Uses `gh pr list` for accurate GitHub data. **TRIGGERS - Use this skill when:** - User asks about open PRs, pull requests, or PR status - User says
$ npx -y skills add espennilsen/pi --skill pr-monitor --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/pr-monitorContext preview
The summary Claude sees to decide when to auto-load this skill.
Monitor open GitHub PRs across all repos in ~/Dev. Checks PR age, flags stale PRs, and optionally alerts via Aivena/Telegram. Uses `gh pr list` for accurate GitHub data. **TRIGGERS - Use this skill when:** - User asks about open PRs, pull requests, or PR status - User says
name: pr-monitor description: | Monitor open GitHub PRs across all repos in ~/Dev. Checks PR age, flags stale PRs, and optionally alerts via Aivena/Telegram. Uses `gh pr list` for accurate GitHub data. **TRIGGERS - Use this skill when:** - User asks about open PRs, pull requests, or PR status - User says "check PRs", "any stale PRs?", "PR review status" - Cron job `pr-monitor` fires - User asks "what needs review?" or "what's waiting for merge?" - User wants a PR dashboard or PR age report
Scan all GitHub-hosted repos in `~/Dev` for open pull requests. Flag stale PRs and report status.
Run this exact command to collect all open PRs:
for dir in ~/Dev/*/; do
if [ -d "$dir/.git" ]; then
remote=$(git -C "$dir" remote get-url origin 2>/dev/null)
if echo "$remote" | grep -q github.com; then
repo=$(echo "$remote" | sed 's/.*github.com[:/]\(.*\)\.git/\1/' | sed 's/.*github.com[:/]\(.*\)/\1/')
prs=$(timeout 30s gh pr list --repo "$repo" --state open --json number,title,createdAt,headRefName,author,isDraft,reviewDecision)
pr_count=$(echo "${prs:-[]}" | jq 'length' 2>/dev/null)
if [ "${pr_count:-0}" -gt 0 ]; then
echo "=== $(basename "$dir") ($repo) ==="
echo "$prs" | jq -r '.[] | " #\(.number) [\(.headRefName)] \(.title) (by \(.author.login), created \(.createdAt[:10]), draft: \(.isDraft), review: \(.reviewDecision // "none"))"'
echo ""
fi
fi
fi
doneFor each PR, calculate age from `createdAt` to today. Classify as:
Output a table with columns:
| Repo | PR | Branch | Title | Author | Age | Status | Review | |------|-----|--------|-------|--------|-----|--------|--------|
Group by repo. Show age badge (🟢/🟡/🔴). Include draft status and review decision.
End with:
**Before sending any Telegram alert**, check today's daily memory log for PRs already covered. Optionally, write a lightweight per-PR "alert sent" timestamp (e.g., `pr-monitor: [repo] #[number] — <date>`) to memory so overlapping executions don't duplicate alerts.
memory_read(target: "daily")
Scan the result for PR references matching `[repo] #[number]`. Any stale PR already mentioned in today's standup or a prior pr-monitor alert **today** should be **excluded** from the new alert.
If net-new stale PRs remain after dedup, send an alert to Aivena via `a2a_send`:
Hey Aivena — PR staleness alert for Espen. Please relay to Telegram. ⚠️ [N] stale PR(s) found (4+ days old, not yet reported today): - [repo] #[number]: [title] ([age] days) ... These need review or merge. — Fury
If no stale PRs exist, or all were already covered today, do nothing (no noise).
This repository is my Pi coding agent home directory. I keep it under version control and symlink it to ~/.pi/agent so Pi loads configuration, extensions, skills, and runtime state from here.
Configure periodic health checks via HEARTBEAT.md and the /heartbeat command.
Manage persistent memory across sessions. Use when asked to remember, recall, forget, or review what was stored. Covers long-term…
Track and manage projects with git status via dashboard and tool.
Delegate tasks to specialized subagents for parallel or sequential execution.
Audit, generate, update, and lint AGENTS.md files across all projects. Use when asked to check project context files, scaffold…