Find the closest bookmark in history to advance it forward #5568
Unanswered
jennings
asked this question in
Nice Revsets
Replies: 2 comments 2 replies
-
The revset to find the commit with the bookmark closest to Some people in the jj community have an alias they call [revset-aliases]
'closest_bookmark(to)' = 'heads(::to | bookmarks())'
[aliases]
tug = ["bookmark", "move", "--from", "closest_bookmark(@-)", "--to", "@-"] Usage: $ jj new my-feature
# work work work
$ jj commit -m "Add some changes"
$ jj tug
# The bookmark my-feature is now at @- If you want to move the bookmark to |
Beta Was this translation helpful? Give feedback.
1 reply
-
Read about the |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
When appending a new commit to a branch using
jj commit
, I need to find the "closest" bookmark to move it forward. Is there a shorter way to do this besidesjj bookmark set my-bookmark -r @-
?Beta Was this translation helpful? Give feedback.
All reactions