1.1 KiB
1.1 KiB
Pushing Changes
When the user asks you to push changes:
# Push a specific bookmark to the remote
jj git push -b <bookmark-name>
# Example: push the main bookmark
jj git push -b main
Before pushing, ensure:
- Your bookmark points to the correct commit (bookmarks don't auto-advance like git branches)
- The commits are refined and atomic
- The user has explicitly requested the push
IMPORTANT: Unlike git branches, jj bookmarks do not automatically move when you create new commits. You must manually update them before pushing:
# Move an existing bookmark to the current commit
jj bookmark move my-feature --to @
# Then push it
jj git push -b my-feature
If no bookmark exists for your changes, create one first:
# Create a bookmark at the current commit
jj bookmark create my-feature
# Then push it
jj git push -b my-feature
For named remotes, multi-remote setups (e.g. fork + upstream), tracking remote bookmarks, and one-time configuration for the two canonical multi-remote workflows, see references/REMOTES.md.