scm
Source code management workflow - nothing is ever lost
安装与使用
请根据来源仓库和你的 AI 工具说明安装此技能。先阅读技能文件和依赖要求,再添加到工作流。
查看来源 ↗使用指南技能说明
Source Code Management
jj workflow for preserving all work. Nothing is ever lost.
Core Principle
Every change is automatically tracked. In jj, working copy (@) is always a commit. No staging area. Every save is part of the current commit.
Rules
-
Commit after every testable change - After each TDD cycle, run
jj commit -m "msg". Don't batch. Worktree gets squash-merged anyway. -
Finalize before destructive ops - Before
jj restore,jj abandon, or ending session: commit first. -
Experiments: commit, try, backout - Commit the experiment, evaluate, then
jj backout -r @-if discarding. History preserved. -
Unknown changes: preserve first - Never
jj restoreunknown changes. Commit checkpoint, then investigate withjj diff -r @-. -
Deleting code: commit, then delete - Checkpoint before removing so you can recover from history.
Why This Matters
-
Recovery: Any past state is one
jj editaway - Confidence: Experiment freely knowing nothing is lost
- Squash merge: All commits collapse to one clean commit at release
Anti-patterns
| Don't | Do Instead |
|---|---|
jj restore without thinking |
Commit first |
jj abandon without checking |
Verify commit is unwanted |
| Batch changes in one commit | Commit after each testable change |
| Leave session without finalizing | Commit before stopping |
使用示例
查看来源仓库中的使用示例与配置说明。
查看来源 ↗来源历史
- 收录时间
- 2026-01-20
- 索引更新时间
- 2026-01-26
- Branch
- main
收录与同步日期属于本站记录。源码修改历史请查看来源仓库。
GitHub ↗chat Comments (0)
Sign in to join the discussion and leave a comment.
No comments yet. Be the first to share your thoughts!