oh-my-claude-sisyphus 1.10.2 → 1.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,31 @@
1
+ #!/bin/bash
2
+ # Sisyphus Stop Continuation Hook
3
+ # Checks for incomplete todos and injects continuation prompt
4
+
5
+ # Read stdin
6
+ INPUT=$(cat)
7
+
8
+ # Check for incomplete todos in the Claude todos directory
9
+ TODOS_DIR="$HOME/.claude/todos"
10
+ if [ -d "$TODOS_DIR" ]; then
11
+ INCOMPLETE_COUNT=0
12
+ for todo_file in "$TODOS_DIR"/*.json; do
13
+ if [ -f "$todo_file" ]; then
14
+ if command -v jq &> /dev/null; then
15
+ COUNT=$(jq '[.[] | select(.status != "completed" and .status != "cancelled")] | length' "$todo_file" 2>/dev/null || echo "0")
16
+ INCOMPLETE_COUNT=$((INCOMPLETE_COUNT + COUNT))
17
+ fi
18
+ fi
19
+ done
20
+
21
+ if [ "$INCOMPLETE_COUNT" -gt 0 ]; then
22
+ cat << EOF
23
+ {"continue": false, "reason": "[SYSTEM REMINDER - TODO CONTINUATION]\n\nIncomplete tasks remain in your todo list ($INCOMPLETE_COUNT remaining). Continue working on the next pending task.\n\n- Proceed without asking for permission\n- Mark each task complete when finished\n- Do not stop until all tasks are done"}
24
+ EOF
25
+ exit 0
26
+ fi
27
+ fi
28
+
29
+ # No incomplete todos - allow stop
30
+ echo '{"continue": true}'
31
+ exit 0
@@ -27,8 +27,20 @@ echo " - Hooks (keyword-detector, silent-auto-update, stop-continuation)"
27
27
  echo " - Version and state files"
28
28
  echo " - Hook configurations from settings.json"
29
29
  echo ""
30
- read -p "Continue? (y/N) " -n 1 -r
31
- echo
30
+ if [ -t 0 ]; then
31
+ read -p "Continue? (y/N) " -n 1 -r
32
+ echo
33
+ else
34
+ # Try reading from terminal if script is piped
35
+ if [ -c /dev/tty ]; then
36
+ echo -n "Continue? (y/N) " >&2
37
+ read -n 1 -r < /dev/tty
38
+ echo
39
+ else
40
+ echo "Non-interactive mode detected or terminal not available. Uninstallation cancelled."
41
+ exit 1
42
+ fi
43
+ fi
32
44
 
33
45
  if [[ ! $REPLY =~ ^[Yy]$ ]]; then
34
46
  echo "Cancelled."
@@ -45,7 +57,6 @@ rm -f "$CLAUDE_CONFIG_DIR/agents/document-writer.md"
45
57
  rm -f "$CLAUDE_CONFIG_DIR/agents/multimodal-looker.md"
46
58
  rm -f "$CLAUDE_CONFIG_DIR/agents/momus.md"
47
59
  rm -f "$CLAUDE_CONFIG_DIR/agents/metis.md"
48
- rm -f "$CLAUDE_CONFIG_DIR/agents/orchestrator-sisyphus.md"
49
60
  rm -f "$CLAUDE_CONFIG_DIR/agents/sisyphus-junior.md"
50
61
  rm -f "$CLAUDE_CONFIG_DIR/agents/prometheus.md"
51
62