shipwright-cli 1.7.1 → 1.10.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.
- package/.claude/agents/code-reviewer.md +90 -0
- package/.claude/agents/devops-engineer.md +142 -0
- package/.claude/agents/pipeline-agent.md +80 -0
- package/.claude/agents/shell-script-specialist.md +150 -0
- package/.claude/agents/test-specialist.md +196 -0
- package/.claude/hooks/post-tool-use.sh +45 -0
- package/.claude/hooks/pre-tool-use.sh +25 -0
- package/.claude/hooks/session-started.sh +37 -0
- package/README.md +212 -814
- package/claude-code/CLAUDE.md.shipwright +54 -0
- package/claude-code/hooks/notify-idle.sh +2 -2
- package/claude-code/hooks/session-start.sh +24 -0
- package/claude-code/hooks/task-completed.sh +6 -2
- package/claude-code/settings.json.template +12 -0
- package/dashboard/public/app.js +4422 -0
- package/dashboard/public/index.html +816 -0
- package/dashboard/public/styles.css +4755 -0
- package/dashboard/server.ts +4315 -0
- package/docs/KNOWN-ISSUES.md +18 -10
- package/docs/TIPS.md +38 -26
- package/docs/patterns/README.md +33 -23
- package/package.json +9 -5
- package/scripts/adapters/iterm2-adapter.sh +1 -1
- package/scripts/adapters/tmux-adapter.sh +52 -23
- package/scripts/adapters/wezterm-adapter.sh +26 -14
- package/scripts/lib/compat.sh +200 -0
- package/scripts/lib/helpers.sh +72 -0
- package/scripts/postinstall.mjs +72 -13
- package/scripts/{cct → sw} +118 -22
- package/scripts/sw-adversarial.sh +274 -0
- package/scripts/sw-architecture-enforcer.sh +330 -0
- package/scripts/sw-checkpoint.sh +468 -0
- package/scripts/sw-cleanup.sh +359 -0
- package/scripts/sw-connect.sh +619 -0
- package/scripts/{cct-cost.sh → sw-cost.sh} +368 -34
- package/scripts/sw-daemon.sh +5574 -0
- package/scripts/sw-dashboard.sh +477 -0
- package/scripts/sw-developer-simulation.sh +252 -0
- package/scripts/sw-docs.sh +635 -0
- package/scripts/sw-doctor.sh +907 -0
- package/scripts/{cct-fix.sh → sw-fix.sh} +10 -6
- package/scripts/{cct-fleet.sh → sw-fleet.sh} +498 -22
- package/scripts/sw-github-checks.sh +521 -0
- package/scripts/sw-github-deploy.sh +533 -0
- package/scripts/sw-github-graphql.sh +972 -0
- package/scripts/sw-heartbeat.sh +293 -0
- package/scripts/{cct-init.sh → sw-init.sh} +144 -11
- package/scripts/sw-intelligence.sh +1196 -0
- package/scripts/sw-jira.sh +643 -0
- package/scripts/sw-launchd.sh +364 -0
- package/scripts/sw-linear.sh +648 -0
- package/scripts/{cct-logs.sh → sw-logs.sh} +72 -2
- package/scripts/sw-loop.sh +2217 -0
- package/scripts/{cct-memory.sh → sw-memory.sh} +514 -36
- package/scripts/sw-patrol-meta.sh +417 -0
- package/scripts/sw-pipeline-composer.sh +455 -0
- package/scripts/sw-pipeline-vitals.sh +1096 -0
- package/scripts/sw-pipeline.sh +7593 -0
- package/scripts/sw-predictive.sh +820 -0
- package/scripts/{cct-prep.sh → sw-prep.sh} +339 -49
- package/scripts/{cct-ps.sh → sw-ps.sh} +9 -6
- package/scripts/{cct-reaper.sh → sw-reaper.sh} +10 -6
- package/scripts/sw-remote.sh +687 -0
- package/scripts/sw-self-optimize.sh +1048 -0
- package/scripts/sw-session.sh +541 -0
- package/scripts/sw-setup.sh +234 -0
- package/scripts/sw-status.sh +796 -0
- package/scripts/{cct-templates.sh → sw-templates.sh} +9 -4
- package/scripts/sw-tmux.sh +591 -0
- package/scripts/sw-tracker-jira.sh +277 -0
- package/scripts/sw-tracker-linear.sh +292 -0
- package/scripts/sw-tracker.sh +409 -0
- package/scripts/{cct-upgrade.sh → sw-upgrade.sh} +103 -46
- package/scripts/{cct-worktree.sh → sw-worktree.sh} +3 -0
- package/templates/pipelines/autonomous.json +35 -6
- package/templates/pipelines/cost-aware.json +21 -0
- package/templates/pipelines/deployed.json +40 -6
- package/templates/pipelines/enterprise.json +16 -2
- package/templates/pipelines/fast.json +19 -0
- package/templates/pipelines/full.json +28 -2
- package/templates/pipelines/hotfix.json +19 -0
- package/templates/pipelines/standard.json +31 -0
- package/tmux/{claude-teams-overlay.conf → shipwright-overlay.conf} +27 -9
- package/tmux/templates/accessibility.json +34 -0
- package/tmux/templates/api-design.json +35 -0
- package/tmux/templates/architecture.json +1 -0
- package/tmux/templates/bug-fix.json +9 -0
- package/tmux/templates/code-review.json +1 -0
- package/tmux/templates/compliance.json +36 -0
- package/tmux/templates/data-pipeline.json +36 -0
- package/tmux/templates/debt-paydown.json +34 -0
- package/tmux/templates/devops.json +1 -0
- package/tmux/templates/documentation.json +1 -0
- package/tmux/templates/exploration.json +1 -0
- package/tmux/templates/feature-dev.json +1 -0
- package/tmux/templates/full-stack.json +8 -0
- package/tmux/templates/i18n.json +34 -0
- package/tmux/templates/incident-response.json +36 -0
- package/tmux/templates/migration.json +1 -0
- package/tmux/templates/observability.json +35 -0
- package/tmux/templates/onboarding.json +33 -0
- package/tmux/templates/performance.json +35 -0
- package/tmux/templates/refactor.json +1 -0
- package/tmux/templates/release.json +35 -0
- package/tmux/templates/security-audit.json +8 -0
- package/tmux/templates/spike.json +34 -0
- package/tmux/templates/testing.json +1 -0
- package/tmux/tmux.conf +98 -9
- package/scripts/cct-cleanup.sh +0 -172
- package/scripts/cct-daemon.sh +0 -3189
- package/scripts/cct-doctor.sh +0 -414
- package/scripts/cct-loop.sh +0 -1332
- package/scripts/cct-pipeline.sh +0 -3844
- package/scripts/cct-session.sh +0 -284
- package/scripts/cct-status.sh +0 -169
package/scripts/cct-cleanup.sh
DELETED
|
@@ -1,172 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env bash
|
|
2
|
-
# ╔═══════════════════════════════════════════════════════════════════════════╗
|
|
3
|
-
# ║ cct-cleanup.sh — Clean up orphaned Claude team sessions ║
|
|
4
|
-
# ║ ║
|
|
5
|
-
# ║ Default: dry-run (shows what would be cleaned). ║
|
|
6
|
-
# ║ Use --force to actually kill sessions and remove files. ║
|
|
7
|
-
# ╚═══════════════════════════════════════════════════════════════════════════╝
|
|
8
|
-
set -euo pipefail
|
|
9
|
-
|
|
10
|
-
# ─── Colors ──────────────────────────────────────────────────────────────────
|
|
11
|
-
CYAN='\033[38;2;0;212;255m'
|
|
12
|
-
PURPLE='\033[38;2;124;58;237m'
|
|
13
|
-
GREEN='\033[38;2;74;222;128m'
|
|
14
|
-
YELLOW='\033[38;2;250;204;21m'
|
|
15
|
-
RED='\033[38;2;248;113;113m'
|
|
16
|
-
DIM='\033[2m'
|
|
17
|
-
BOLD='\033[1m'
|
|
18
|
-
RESET='\033[0m'
|
|
19
|
-
|
|
20
|
-
info() { echo -e "${CYAN}${BOLD}▸${RESET} $*"; }
|
|
21
|
-
success() { echo -e "${GREEN}${BOLD}✓${RESET} $*"; }
|
|
22
|
-
warn() { echo -e "${YELLOW}${BOLD}⚠${RESET} $*"; }
|
|
23
|
-
error() { echo -e "${RED}${BOLD}✗${RESET} $*" >&2; }
|
|
24
|
-
|
|
25
|
-
# ─── Parse Args ──────────────────────────────────────────────────────────────
|
|
26
|
-
|
|
27
|
-
FORCE=false
|
|
28
|
-
for arg in "$@"; do
|
|
29
|
-
case "$arg" in
|
|
30
|
-
--force|-f) FORCE=true ;;
|
|
31
|
-
--help|-h)
|
|
32
|
-
echo -e "${CYAN}${BOLD}shipwright cleanup${RESET} — Clean up orphaned Claude team sessions"
|
|
33
|
-
echo ""
|
|
34
|
-
echo -e "${BOLD}USAGE${RESET}"
|
|
35
|
-
echo -e " shipwright cleanup ${DIM}# Dry-run: show what would be cleaned${RESET}"
|
|
36
|
-
echo -e " shipwright cleanup --force ${DIM}# Actually kill sessions and remove files${RESET}"
|
|
37
|
-
exit 0
|
|
38
|
-
;;
|
|
39
|
-
*)
|
|
40
|
-
error "Unknown option: ${arg}"
|
|
41
|
-
exit 1
|
|
42
|
-
;;
|
|
43
|
-
esac
|
|
44
|
-
done
|
|
45
|
-
|
|
46
|
-
# ─── Track cleanup stats ────────────────────────────────────────────────────
|
|
47
|
-
|
|
48
|
-
WINDOWS_FOUND=0
|
|
49
|
-
WINDOWS_KILLED=0
|
|
50
|
-
TEAM_DIRS_FOUND=0
|
|
51
|
-
TEAM_DIRS_REMOVED=0
|
|
52
|
-
TASK_DIRS_FOUND=0
|
|
53
|
-
TASK_DIRS_REMOVED=0
|
|
54
|
-
|
|
55
|
-
# ─── 1. Find orphaned tmux windows ──────────────────────────────────────────
|
|
56
|
-
|
|
57
|
-
echo ""
|
|
58
|
-
if $FORCE; then
|
|
59
|
-
info "Cleaning up Claude team sessions ${RED}${BOLD}(FORCE MODE)${RESET}"
|
|
60
|
-
else
|
|
61
|
-
info "Scanning for orphaned Claude team sessions ${DIM}(dry-run)${RESET}"
|
|
62
|
-
fi
|
|
63
|
-
echo ""
|
|
64
|
-
|
|
65
|
-
echo -e "${BOLD}Tmux Windows${RESET}"
|
|
66
|
-
echo -e "${DIM}────────────────────────────────────────${RESET}"
|
|
67
|
-
|
|
68
|
-
# Look for windows with "claude" in the name across all sessions
|
|
69
|
-
CLAUDE_WINDOWS=()
|
|
70
|
-
while IFS= read -r line; do
|
|
71
|
-
[[ -n "$line" ]] && CLAUDE_WINDOWS+=("$line")
|
|
72
|
-
done < <(tmux list-windows -a -F '#{session_name}:#{window_index} #{window_name}' 2>/dev/null | grep -i "claude" || true)
|
|
73
|
-
|
|
74
|
-
if [[ ${#CLAUDE_WINDOWS[@]} -eq 0 ]]; then
|
|
75
|
-
echo -e " ${DIM}No Claude team windows found.${RESET}"
|
|
76
|
-
else
|
|
77
|
-
for win in "${CLAUDE_WINDOWS[@]}"; do
|
|
78
|
-
WINDOWS_FOUND=$((WINDOWS_FOUND + 1))
|
|
79
|
-
local_target="$(echo "$win" | cut -d' ' -f1)"
|
|
80
|
-
local_name="$(echo "$win" | cut -d' ' -f2-)"
|
|
81
|
-
|
|
82
|
-
if $FORCE; then
|
|
83
|
-
tmux kill-window -t "$local_target" 2>/dev/null && {
|
|
84
|
-
echo -e " ${RED}✗${RESET} Killed: ${local_name} ${DIM}(${local_target})${RESET}"
|
|
85
|
-
WINDOWS_KILLED=$((WINDOWS_KILLED + 1))
|
|
86
|
-
} || {
|
|
87
|
-
warn " Could not kill: ${local_name} (${local_target})"
|
|
88
|
-
}
|
|
89
|
-
else
|
|
90
|
-
echo -e " ${YELLOW}○${RESET} Would kill: ${local_name} ${DIM}(${local_target})${RESET}"
|
|
91
|
-
fi
|
|
92
|
-
done
|
|
93
|
-
fi
|
|
94
|
-
|
|
95
|
-
# ─── 2. Clean up ~/.claude/teams/ ───────────────────────────────────────────
|
|
96
|
-
|
|
97
|
-
echo ""
|
|
98
|
-
echo -e "${BOLD}Team Configs${RESET} ${DIM}~/.claude/teams/${RESET}"
|
|
99
|
-
echo -e "${DIM}────────────────────────────────────────${RESET}"
|
|
100
|
-
|
|
101
|
-
TEAMS_DIR="${HOME}/.claude/teams"
|
|
102
|
-
if [[ -d "$TEAMS_DIR" ]]; then
|
|
103
|
-
while IFS= read -r team_dir; do
|
|
104
|
-
[[ -z "$team_dir" ]] && continue
|
|
105
|
-
TEAM_DIRS_FOUND=$((TEAM_DIRS_FOUND + 1))
|
|
106
|
-
team_name="$(basename "$team_dir")"
|
|
107
|
-
|
|
108
|
-
if $FORCE; then
|
|
109
|
-
rm -rf "$team_dir" && {
|
|
110
|
-
echo -e " ${RED}✗${RESET} Removed: ${team_name}/"
|
|
111
|
-
TEAM_DIRS_REMOVED=$((TEAM_DIRS_REMOVED + 1))
|
|
112
|
-
}
|
|
113
|
-
else
|
|
114
|
-
# Count files inside
|
|
115
|
-
file_count=$(find "$team_dir" -type f 2>/dev/null | wc -l | tr -d ' ')
|
|
116
|
-
echo -e " ${YELLOW}○${RESET} Would remove: ${team_name}/ ${DIM}(${file_count} files)${RESET}"
|
|
117
|
-
fi
|
|
118
|
-
done < <(find "$TEAMS_DIR" -mindepth 1 -maxdepth 1 -type d 2>/dev/null)
|
|
119
|
-
else
|
|
120
|
-
echo -e " ${DIM}No team configs found.${RESET}"
|
|
121
|
-
fi
|
|
122
|
-
|
|
123
|
-
# ─── 3. Clean up ~/.claude/tasks/ ───────────────────────────────────────────
|
|
124
|
-
|
|
125
|
-
echo ""
|
|
126
|
-
echo -e "${BOLD}Task Lists${RESET} ${DIM}~/.claude/tasks/${RESET}"
|
|
127
|
-
echo -e "${DIM}────────────────────────────────────────${RESET}"
|
|
128
|
-
|
|
129
|
-
TASKS_DIR="${HOME}/.claude/tasks"
|
|
130
|
-
if [[ -d "$TASKS_DIR" ]]; then
|
|
131
|
-
while IFS= read -r task_dir; do
|
|
132
|
-
[[ -z "$task_dir" ]] && continue
|
|
133
|
-
TASK_DIRS_FOUND=$((TASK_DIRS_FOUND + 1))
|
|
134
|
-
task_name="$(basename "$task_dir")"
|
|
135
|
-
|
|
136
|
-
if $FORCE; then
|
|
137
|
-
rm -rf "$task_dir" && {
|
|
138
|
-
echo -e " ${RED}✗${RESET} Removed: ${task_name}/"
|
|
139
|
-
TASK_DIRS_REMOVED=$((TASK_DIRS_REMOVED + 1))
|
|
140
|
-
}
|
|
141
|
-
else
|
|
142
|
-
task_count=$(find "$task_dir" -type f -name '*.json' 2>/dev/null | wc -l | tr -d ' ')
|
|
143
|
-
echo -e " ${YELLOW}○${RESET} Would remove: ${task_name}/ ${DIM}(${task_count} tasks)${RESET}"
|
|
144
|
-
fi
|
|
145
|
-
done < <(find "$TASKS_DIR" -mindepth 1 -maxdepth 1 -type d 2>/dev/null)
|
|
146
|
-
else
|
|
147
|
-
echo -e " ${DIM}No task directories found.${RESET}"
|
|
148
|
-
fi
|
|
149
|
-
|
|
150
|
-
# ─── Summary ─────────────────────────────────────────────────────────────────
|
|
151
|
-
|
|
152
|
-
echo ""
|
|
153
|
-
echo -e "${DIM}────────────────────────────────────────${RESET}"
|
|
154
|
-
|
|
155
|
-
TOTAL_FOUND=$((WINDOWS_FOUND + TEAM_DIRS_FOUND + TASK_DIRS_FOUND))
|
|
156
|
-
|
|
157
|
-
if $FORCE; then
|
|
158
|
-
TOTAL_CLEANED=$((WINDOWS_KILLED + TEAM_DIRS_REMOVED + TASK_DIRS_REMOVED))
|
|
159
|
-
if [[ $TOTAL_CLEANED -gt 0 ]]; then
|
|
160
|
-
success "Cleaned ${TOTAL_CLEANED} items (${WINDOWS_KILLED} windows, ${TEAM_DIRS_REMOVED} team dirs, ${TASK_DIRS_REMOVED} task dirs)"
|
|
161
|
-
else
|
|
162
|
-
success "Nothing to clean up."
|
|
163
|
-
fi
|
|
164
|
-
else
|
|
165
|
-
if [[ $TOTAL_FOUND -gt 0 ]]; then
|
|
166
|
-
warn "Found ${TOTAL_FOUND} items to clean. Run with ${BOLD}--force${RESET} to remove them:"
|
|
167
|
-
echo -e " ${DIM}shipwright cleanup --force${RESET}"
|
|
168
|
-
else
|
|
169
|
-
success "Everything is clean. No orphaned sessions found."
|
|
170
|
-
fi
|
|
171
|
-
fi
|
|
172
|
-
echo ""
|