All of lore.kernel.org
 help / color / mirror / Atom feed
* How to display "HEAD~*" in "git log"
@ 2022-07-05  7:11 wuzhouhui
  2022-07-05  9:25 ` Konstantin Khomoutov
  0 siblings, 1 reply; 11+ messages in thread
From: wuzhouhui @ 2022-07-05  7:11 UTC (permalink / raw)
  To: git

Hi

I frequently use "git rebase" to move commit to a specific location, to
know which commit ID as param of "git rebase", I have to list all commits
by "git log --oneline", then copy specific commit ID, and executing "git
rebase" as

   git rebase -i <copied commit ID>~

because SHA sum is hard to memorize, so I have to use copy and past,
which is too boring. So, I wonder if there is a way to let "git log"
display commits like following:

   HEAD   <one line commit message>
   HEAD~1 <one line commit message>
HEAD~2 <one line commit message>
HEAD~3 <one line commit message>
   ...

With these "HEAD~*", I can easily directly type them and no need to
move my fingers out of keyboard.

Thanks.


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2022-07-07 17:06 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-05  7:11 How to display "HEAD~*" in "git log" wuzhouhui
2022-07-05  9:25 ` Konstantin Khomoutov
2022-07-05  9:30   ` Konstantin Khomoutov
2022-07-05  9:36     ` wuzhouhui
2022-07-06 12:38       ` kostix
2022-07-06 14:38   ` Jeff King
2022-07-06 16:28     ` Konstantin Khomoutov
2022-07-06 16:49       ` Jeff King
2022-07-06 18:21         ` Konstantin Khomoutov
2022-07-07 17:06           ` Jeff King
2022-07-06 17:31     ` Junio C Hamano

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.