Loading...
Loading...
Navigation and restacking with Graphite (gt)
npx skill4agent add kalbasit/ncps graphitegtgt ssgt submitgt squashgtgt restackgt getgt sync| Command | Action |
|---|---|
| Move to the branch immediately above the current one in the stack. |
| Move to the parent of the current branch. |
| Move to the previous branch in the stack, as ordered by |
| Move to the next branch in the stack, as ordered by |
| Move to the tip branch of the current stack. |
| Move to the branch closest to trunk in the current stack. |
| Display all tracked branches and their dependency relationships in a short format. |
| Command | Action |
|---|---|
| Ensure each branch in the current stack has its parent in its Git commit history, rebasing if necessary. This maintains the local stack and does NOT reach out to upstream. |
| Sync a specific branch or stack from remote (trunk to branch). If no branch is provided, it syncs the current stack. |
| Sync all branches (including trunk) from remote and prompt to delete merged branches. |
| Command | Action |
|---|---|
| Create a new branch with the given name and stack it on top of the current one. Always follow the |
| Rebase the current branch onto a target branch and restack descendants. Use |
| Split the current branch into multiple branches. This command is highly interactive. |
gt modify| Command | Action |
|---|---|
| Amend the head commit of the current branch. |
| Create a new commit on the current branch. Preferred for adding new changes while keeping history clean. |
gt modifygt movegt splitgt restackgt restackgt movegit status<<<<<<<=======>>>>>>>gt add -Agit add <file>gt continuegit rebase --continue--ontogt movegit commitgit commit --amendgtgitgt create <branch-name>git checkout -b <branch-name>gt modify -c -m "message"git commit -m "message"gt modify --amendgit commit --amendgt modify -cam "message"git commit -am "message"git stashgt create <new-branch>gt downgit reset --hard HEAD~1git reset HEAD~1gt downgt upgt modify -cgt modify --amendgit stash popgt restack[!CAUTION] DO NOT use the following commands under any circumstances:
gt ssgt submitgt squash