Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

executing-sequential-phase

БесплатноБез исполняемых скриптовНе проверен

Use when orchestrating sequential phases in plan execution - executes tasks one-by-one in main worktree using git-spice natural stacking (NO manual upstack…

arittrот arittr★ 20 звёзд на GitHub12 установок в других каталогах

Об этом скилле

Executing Sequential Phase

Overview

Sequential phases use natural git-spice stacking in the main worktree.

Each task creates a branch with gs branch create, which automatically stacks on the current HEAD. No manual stacking operations needed.

Critical distinction: Sequential tasks BUILD ON each other. They need integration, not isolation.

When to Use

Use this skill when execute command encounters a phase marked "Sequential" in plan.md:

  • ✅ Tasks must run in order (dependencies)
  • ✅ Execute in existing {runid}-main worktree
  • ✅ Trust natural stacking (no manual gs upstack onto)
  • ✅ Stay on task branches (don't switch to base between tasks)

Sequential phases never use worktrees. They share one workspace where tasks build cumulatively.

Multi-Repo Support

Receiving Multi-Repo Context

The orchestrator passes:

  • WORKSPACE_MODE: "multi-repo" or "single-repo"
  • WORKSPACE_ROOT: Absolute path to workspace
  • Per-task TASK_REPO from plan

Sequential Execution Across Repos

In multi-repo mode, sequential tasks may span repos:

Phase 1 (sequential):
- Task 1.1: repo=shared-lib  # Shared types first
- Task 1.2: repo=backend     # Backend uses shared types
- Task 1.3: repo=frontend    # Frontend uses shared types

For each task, switch to that task's repo context.

Per-Repo Worktrees

In multi-repo sequential phases:

  • Each repo has its own main worktree: {repo}/.worktrees/{runId}-main/
  • Tasks execute in their repo's worktree
  • Switching tasks = switching repos (if different)

Per-Repo Setup Commands

Read setup commands from each task's repo:

# Multi-repo: Read from task's repo CLAUDE.md
INSTALL_CMD=$(grep -A1 "**install**:" ${TASK_REPO}/CLAUDE.md | tail -1)

Per-Repo Constitution

Pass correct constitution to subagents:

# Multi-repo
CONSTITUTION="@${TASK_REPO}/docs/constitutions/current/"

Per-Repo Stacking

Sequential tasks across repos create per-repo stacks:

Execution order:
1. Task 1.1 (shared-lib) → creates branch in shared-lib
2. Task 1.2 (backend) → creates branch in backend
3. Task 1.3 (backend) → stacks on 1.2 in backend
4. Task 1.4 (frontend) → creates branch in frontend

Result:
- shared-lib stack: task-1-1
- backend stack: task-1-2 → task-1-3
- frontend stack: task-1-4

Each repo maintains its own linear stack. Cannot stack across repos.

Single-Repo Mode (Unchanged)

All existing behavior preserved:

  • Single main worktree at .worktrees/{runId}-main/
  • Single CLAUDE.md for setup commands
  • Single constitution at @docs/constitutions/current/
  • Single linear stack of branches

The Natural Stacking Principle

SEQUENTIAL PHASE = MAIN WORKTREE + NATURAL STACKING

What natural stacking means:

  1. Start on base branch (or previous task's branch)
  2. Create new branch with gs branch create → automatically stacks on current
  3. Stay on that branch when done
  4. Next task creates from there → automatically stacks on previous

No manual commands needed. The workflow IS the stacking.

The Process

Announce: "I'm using executing-sequential-phase to execute {N} tasks sequentially in Phase {phase-id}."

Step 0: Verify Orchestrator Location

MANDATORY: Verify orchestrator is in correct location before any operations:

Single-repo mode:

REPO_ROOT=$(git rev-parse --show-toplevel)
CURRENT=$(pwd)

if [ "$CURRENT" != "$REPO_ROOT" ]; then
  echo "❌ Error: Orchestrator must run from main repo root"
  echo "Current: $CURRENT"
  echo "Expected: $REPO_ROOT"
  echo ""
  echo "Return to main repo: cd $REPO_ROOT"
  exit 1
fi

echo "✅ Orchestrator location verified: Main repo root"

Multi-repo mode:

# Orchestrator runs from WORKSPACE_ROOT (parent of all repos)
CURRENT=$(pwd)

if [ "$CURRENT" != "$WORKSPACE_ROOT" ]; then
  echo "❌ Error: Orchestrator must run from workspace root"
  echo "Current: $CURRENT"
  echo "Expected: $WORKSPACE_ROOT"
  echo ""
  echo "Return to workspace: cd $WORKSPACE_ROOT"
  exit 1
fi

echo "✅ Orchestrator location verified: Workspace root ($WORKSPACE_MODE mode)"

Why critical:

  • Orchestrator delegates work but never changes directory
  • Single-repo: All operations use git -C .worktrees/path or bash -c "cd path && cmd"
  • Multi-repo: All operations use git -C {repo}/.worktrees/path or bash -c "cd {repo}/path && cmd"
  • This assertion catches upstream drift immediately

Step 1: Verify Setup and Base Branch

First, verify we're on the correct base branch for this phase:

Single-repo mode:

# Get current branch in main worktree
CURRENT_BRANCH=$(git -C .worktrees/{runid}-main branch --show-current)
EXPECTED_BASE="{expected-base-branch}"  # From plan: previous phase's last task, or {runid}-main for Phase 1

if [ "$CURRENT_BRANCH" != "$EXPECTED_BASE" ]; then
  echo "⚠️  WARNING: Phase {phase-id} starting from unexpected branch"
  echo "   Current: $CURRENT_BRANCH"
  echo "   Expected: $EXPECTED_BASE"
  echo
Полный SKILL.md на GitHub

Установить executing-sequential-phase в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

test-scenarios.md

FAQ

Что делает скилл executing-sequential-phase?

Use when orchestrating sequential phases in plan execution - executes tasks one-by-one in main worktree using git-spice natural stacking (NO manual upstack commands, NO worktree creation, tasks build on each other)

Как установить скилл executing-sequential-phase?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл executing-sequential-phase запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить executing-sequential-phase с