一键导入
sg-update
Use this when GSD, Superpowers, or super-gsd may be outdated — checks each tool's installation status and installs or updates to the latest version.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Use this when GSD, Superpowers, or super-gsd may be outdated — checks each tool's installation status and installs or updates to the latest version.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | sg-update |
| description | Use this when GSD, Superpowers, or super-gsd may be outdated — checks each tool's installation status and installs or updates to the latest version. |
| argument-hint | No arguments needed. |
<execution_context> Self-contained. Uses Bash to run detection and install/update commands. </execution_context>
Run the following single bash block. All steps run in one shell process so variables persist through the summary.echo "Updating workflow tools..."
# Preflight: check for claude CLI
if ! command -v claude >/dev/null 2>&1; then
echo "Warning: 'claude' CLI not found on PATH. Plugin steps (superpowers, super-gsd) will be skipped."
CLAUDE_AVAILABLE=false
else
CLAUDE_AVAILABLE=true
fi
# GSD (@opengsd/get-shit-done-redux)
if command -v gsd-sdk >/dev/null 2>&1 || npm list -g --depth=0 @opengsd/get-shit-done-redux >/dev/null 2>&1; then
echo "Updating GSD..."
GSD_BEFORE=$(gsd-sdk --version 2>/dev/null || npm list -g --depth=0 @opengsd/get-shit-done-redux 2>/dev/null | grep -Eo '[0-9]+\.[0-9]+\.[0-9]+' | head -1 || echo 'unknown')
NPM_OUT=$(npm install -g @opengsd/get-shit-done-redux@latest 2>&1)
NPM_EC=$?
echo "$NPM_OUT" | tail -3
if [ "$NPM_EC" -ne 0 ]; then
GSD_STATUS="failed (exit ${NPM_EC})"
else
GSD_AFTER=$(gsd-sdk --version 2>/dev/null || npm list -g --depth=0 @opengsd/get-shit-done-redux 2>/dev/null | grep -Eo '[0-9]+\.[0-9]+\.[0-9]+' | head -1 || echo 'unknown')
GSD_STATUS="updated (${GSD_BEFORE} → ${GSD_AFTER})"
fi
else
echo "Installing GSD..."
NPM_OUT=$(npm install -g @opengsd/get-shit-done-redux@latest 2>&1)
NPM_EC=$?
echo "$NPM_OUT" | tail -3
if [ "$NPM_EC" -eq 0 ]; then
GSD_STATUS="installed"
else
GSD_STATUS="failed (exit ${NPM_EC})"
fi
fi
# superpowers
if [ "$CLAUDE_AVAILABLE" = "true" ]; then
if claude plugin list 2>&1 | grep -qiF 'superpowers'; then
echo "Updating superpowers..."
claude plugin install superpowers@claude-plugins-official 2>&1
PLUGIN_EC=$?
if [ "$PLUGIN_EC" -eq 0 ]; then
SUPERPOWERS_VER=$(claude plugin list 2>&1 | grep -i 'superpowers' | grep -oE '[0-9]+\.[0-9]+\.[0-9]+' | head -1)
if [ -n "$SUPERPOWERS_VER" ]; then
SUPERPOWERS_STATUS="updated (${SUPERPOWERS_VER})"
else
SUPERPOWERS_STATUS="updated"
fi
else
SUPERPOWERS_STATUS="failed (exit ${PLUGIN_EC})"
fi
else
echo "Installing superpowers..."
claude plugin install superpowers@claude-plugins-official 2>&1
PLUGIN_EC=$?
if [ "$PLUGIN_EC" -eq 0 ]; then
SUPERPOWERS_VER=$(claude plugin list 2>&1 | grep -i 'superpowers' | grep -oE '[0-9]+\.[0-9]+\.[0-9]+' | head -1)
if [ -n "$SUPERPOWERS_VER" ]; then
SUPERPOWERS_STATUS="installed (${SUPERPOWERS_VER})"
else
SUPERPOWERS_STATUS="installed"
fi
else
SUPERPOWERS_STATUS="failed (exit ${PLUGIN_EC})"
fi
fi
else
SUPERPOWERS_STATUS="skipped (claude not found)"
fi
# super-gsd
if [ "$CLAUDE_AVAILABLE" = "true" ]; then
if claude plugin list 2>&1 | grep -qiF 'super-gsd'; then
echo "Updating super-gsd..."
claude plugin install super-gsd@super-gsd 2>&1
PLUGIN_EC=$?
if [ "$PLUGIN_EC" -eq 0 ]; then
SUPERGSD_VER=$(claude plugin list 2>&1 | grep -i 'super-gsd' | grep -oE '[0-9]+\.[0-9]+\.[0-9]+' | head -1)
if [ -n "$SUPERGSD_VER" ]; then
SUPERGSD_STATUS="updated (${SUPERGSD_VER})"
else
SUPERGSD_STATUS="updated"
fi
else
SUPERGSD_STATUS="failed (exit ${PLUGIN_EC})"
fi
else
echo "Installing super-gsd..."
claude plugin install super-gsd@super-gsd 2>&1
PLUGIN_EC=$?
if [ "$PLUGIN_EC" -eq 0 ]; then
SUPERGSD_VER=$(claude plugin list 2>&1 | grep -i 'super-gsd' | grep -oE '[0-9]+\.[0-9]+\.[0-9]+' | head -1)
if [ -n "$SUPERGSD_VER" ]; then
SUPERGSD_STATUS="installed (${SUPERGSD_VER})"
else
SUPERGSD_STATUS="installed"
fi
else
SUPERGSD_STATUS="failed (exit ${PLUGIN_EC})"
fi
fi
else
SUPERGSD_STATUS="skipped (claude not found)"
fi
echo ""
echo "Done."
echo ""
echo "Tools:"
echo "- GSD (@opengsd/get-shit-done-redux): ${GSD_STATUS}"
echo "- superpowers: ${SUPERPOWERS_STATUS}"
echo "- super-gsd: ${SUPERGSD_STATUS}"
echo ""
echo "Restart Claude Code to activate updated plugins."
After the bash block completes, relay its output to the user verbatim.
<success_criteria>
Detect the current workflow stage from HANDOFF.md and STATE.md and report the next sg-* skill to activate.
Detect existing session or start new project — super-gsd workflow entry point
Display current workflow stage, last handoff timestamp, and next recommended command
Toggle the sg-learn stage on or off in the super-gsd workflow by flipping super_gsd.skip_learn in .planning/config.json. Accepts on|off, or no argument to flip.
Toggle the sg-review stage on or off in the super-gsd workflow by flipping super_gsd.skip_review in .planning/config.json. Accepts on|off, or no argument to flip.
Toggle the sg-tdd stage on or off in the super-gsd workflow by flipping super_gsd.tdd_mode in .planning/config.json. Accepts on|off, or no argument to flip.