Git cherry combined with git show

I use Git Cherry and would like to see more details about the commits found. First i run

git cherry -- read the output git show sha-1 

Is there a way to see the commit / log / diff for all cherry and page results through them? I tried passing the results of git cherries to different things, but didn't seem to find what works.

+4
source share
1 answer

I don’t have a β€œcomplete” answer, but these quick hacks can be useful:

 $ git cherry master + c3f6a19ac55170baa33fbbfb583ff3f0d4ad2710 + 8b73d6cb31d0a3fed328acd31d524a671238f51a $ git cherry -v master + c3f6a19ac55170baa33fbbfb583ff3f0d4ad2710 Add "foo" command + 8b73d6cb31d0a3fed328acd31d524a671238f51a Add "--bar" argument $ git cherry master | awk '{ system("git show $2"); }' [ interactive "git show" calls happen here ] $ 

Other problems:

  • You don’t see if git show n really has the + prefix.
  • You have no way from git show to abort the whole operation.
  • You do not have to exit git show to see if the displayed message is 1/100, 1/2 or 88/100.
+5
source

Source: https://habr.com/ru/post/1335654/


All Articles