Skip to main content

df-new

Use when Delong invokes /df-new to start a fresh piece of work — opens a new worktree off latest staging, plans, and builds with agents as plain commits until /df-create-pr.

소스 정보

저장소
delfu/dotfiles
최근 소스 활동
2026년 10월 5일 20:32
감지된 SKILL.md 언어
영어
스타
0
포크
0

설치 방법

기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.

소스 파일 검토

설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.

SKILL.md 표시 중

SKILL.md
소스 지침 · 읽기 전용 미리보기
name
df-new
description
Use when Delong invokes /df-new to start a fresh piece of work — opens a new worktree off latest staging, plans, and builds with agents as plain commits until /df-create-pr.
user-invocable
true
argument-hint
<what to build>
# New work session (Delong) Start one focused idea in its own worktree, cut from the latest `origin/staging`. Build it with plain commits on one branch. Graphite is not involved until `/df-create-pr`. Related: `/df-next` stacks new work on an existing stack; `/df-create-pr` publishes. ## When NOT to Use - To build on top of an existing stack → `/df-next`. - To fix review comments on an open PR → work in that PR's worktree (`review-pr-comments`). ## Workflow ### 1. Get into a fresh worktree ```bash MAIN_ROOT=$(dirname "$(git rev-parse --path-format=absolute --git-common-dir)") CUR_ROOT=$(git rev-parse --show-toplevel) git -C "$MAIN_ROOT" fetch origin staging ``` Pick a short kebab-case `<slug>` from the task (ask only if `$ARGUMENTS` is empty). Then: - **Already in a linked worktree that is untouched**: this is the desktop app's per-session worktree. The test is `CUR_ROOT != MAIN_ROOT`, `git status --porcelain` is empty, and `git log origin/staging..HEAD` is empty. Reuse it. Run `git reset --keep origin/staging` so it starts on latest staging. Rename the branch with `git branch -m delong/<slug>`. - **Otherwise** (main checkout, or a worktree that already has work), create a new worktree. Never stack unrelated work on top of an existing branch. ```bash WT="$MAIN_ROOT/.claude/worktrees/<slug>" git -C "$MAIN_ROOT" worktree add "$WT" -b "delong/<slug>" origin/staging ``` Then call **EnterWorktree** with `path: "$WT"` so the session moves into it. Record where the branch came from. `/df-create-pr` reads this: ```bash git config "branch.delong/<slug>.delong-parent" staging ``` Run `./.worktreesetup` in the background from the worktree root. The SessionStart hook does not fire for a worktree created mid-session. If the task is clearly one project, scope the setup, for example `WORKTREESETUP_PROJECTS=desktop`. ### 2. Plan Follow the repo's AGENTS.md rule. For anything non-trivial (new feature, multi-file change, bug with unknowns), run the `ce-plan` skill first. Skip planning for one-liners and mechanical changes. Use the repo's preferred skills and agents for the area (see the Skill Priority table), for example `ui-dev` for desktop UI and `backend-py-dev` for aria-web. ### 3. Build - Dispatch subagents for independent pieces of the plan. Run them in parallel when they touch different files. Give each one the worktree path as its working directory. Don't use `isolation: "worktree"`: their changes must land in this worktree. - Commit as you go with plain `git commit` on `delong/<slug>`. Stage by explicit path. Never use `git add -A` or `-a`, and never stage `flow-server/vendor/vime`. - Keep commits shaped around ideas: one refactor, one feature step, and so on. `/df-create-pr` splits the stack along commit lines, so clean commits now mean an easy split later. - Don't run `gt create` or `gt submit`, and don't push. Publishing is `/df-create-pr`'s job. - Run the touched project's typecheck, lint and tests before saying a step is done. ### 4. Hand back Report what was built, the commits, what was verified, and what wasn't. End with the next step: `/df-create-pr` when ready for review. ## Common Pitfalls - `git checkout staging` / `gt checkout staging` fail inside a worktree, because the main checkout owns `staging`. Always base on `origin/staging`. - Don't run `git stash` (it's shared across worktrees). Use a WIP commit instead. - One idea per session. If the work grows a second, unrelated idea, say so. Suggest finishing this one and starting the other with `/df-new` or `/df-next`.
GitHub에서 보기