Skip to content

feat(#122): add --base flag to sequant run for custom base branches - #123

Merged
admarble merged 1 commit into
mainfrom
feature/122-feat-add-base-flag-to-sequant-run-for-custom-base-
Jan 19, 2026
Merged

admarble merged 1 commit into
mainfrom
feature/122-feat-add-base-flag-to-sequant-run-for-custom-base-

Conversation

@admarble

Copy link
Copy Markdown
Contributor

Summary

  • Add --base <branch> CLI option to sequant run command for custom base branches
  • Add defaultBase field to RunSettings for project-level configuration
  • Update worktree creation functions to support custom base branches
  • Update /solve, /exec, /spec skills to document and recommend base branch usage
  • Add docs/feature-branch-workflow.md documentation guide

Changes

File Change
bin/cli.ts Add --base option to run command
src/lib/settings.ts Add defaultBase to RunSettings interface
src/commands/run.ts Resolve base branch and pass to worktree functions
templates/scripts/new-feature.sh Accept --base flag for worktree creation
.claude/skills/solve/SKILL.md Document --base usage and detection
.claude/skills/exec/SKILL.md Document base branch in worktree creation
.claude/skills/spec/SKILL.md Add feature branch context detection
README.md Add --base usage examples
docs/feature-branch-workflow.md New guide for feature branch workflows

Resolution Priority

1. --base <branch> flag      →  Explicit override (highest priority)
2. .sequant/settings.json    →  defaultBase field (project config)
3. Repository default branch →  main (safe fallback)

Example Usage

# Explicit flag (one-off override)
npx sequant run 117 --base feature/dashboard

# Project config (persistent for all runs)
# .sequant/settings.json: { "run": { "defaultBase": "feature/dashboard" } }
npx sequant run 117  # Uses feature/dashboard from config

# Chain mode with custom base
npx sequant run 117 118 119 --sequential --chain --base feature/dashboard

Test plan

  • npm test passes (438 tests)
  • npm run build succeeds
  • CLI help shows --base option
  • Manual test: npx sequant run <issue> --base <branch> creates worktree from specified branch
  • Manual test: Settings file defaultBase is respected when no flag provided

Closes #122

🤖 Generated with Claude Code

Add support for custom base branches in worktree creation, enabling
feature integration branch workflows. Users can now branch from a
custom base instead of main when running sequant workflows.

Changes:
- Add --base <branch> CLI option to `sequant run` command
- Add `defaultBase` field to RunSettings for project-level config
- Update ensureWorktree(s) and ensureWorktreesChain to accept base branch
- Update new-feature.sh script to support --base flag
- Update /solve, /exec, /spec skills to document base branch usage
- Add feature-branch-workflow.md documentation guide
- Update README.md with --base examples

Resolution priority: CLI --base flag → settings.run.defaultBase → main

Closes #122

Co-Authored-By: Claude Opus 4.5 <[email protected]>
@admarble
admarble merged commit e6e1440 into main Jan 19, 2026
@admarble
admarble deleted the feature/122-feat-add-base-flag-to-sequant-run-for-custom-base- branch January 19, 2026 05:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: add --base flag to sequant run for custom base branches

1 participant