lazygit icon indicating copy to clipboard operation
lazygit copied to clipboard

Logs are not represented as in the demo

Open plaffitt opened this issue 1 year ago • 2 comments

Describe the bug The log panel doesn't show pretty logs like in the demo.

To Reproduce

  1. Open lazy git and select a branch

Expected behavior

I want to see something like this (or at least some documentation that explains how to configure lazy git to do it) :

image

But I see this :

image

Or this :

image

Version info: lazygit: commit=6fcb7eb8bb616c170506312870b3bf15f3dbe37c, build date=2024-05-19T10:15:28Z, build source=binaryRelease, version=0.42.0, os=linux, arch=amd64, git version=2.34.1 git: git version 2.34.1

plaffitt avatar Jul 11 '24 10:07 plaffitt

Try using zoomed modes by pressing + or _, I think that'll do it.

mark2185 avatar Jul 11 '24 10:07 mark2185

I found how to do, either set git.log.showWholeGraph: true or Log menu -> Show git graph (<c-l> in the commits window by default). But I still wonder why the commits panel isn't configurable like the log one (git.branchLogCmd) and what command exactly produce the output of the commit panel ?

plaffitt avatar Jul 25 '24 09:07 plaffitt

/close

Thankfully, the behavior you want is now default! As of https://github.com/jesseduffield/lazygit/pull/3314,git.log.showGraph now defaults to always, which gives you the pretty graph. showWholeGraph is actually precisely about whether you see unmerged histories in the graph, or just the history converging on your current branch.

But I still wonder why the commits panel isn't configurable like the log one (git.branchLogCmd) and what command exactly produce the output of the commit panel ?

The reason it isn't is that this is a commit graph that is being built inside of Lazygit, where the log panel is just us throwing a command out into the world, and rendering whatever it gives back to us in that panel. So the configuration options are whatever we have built custom.

Check out here if you want to see some of the logic to render that pretty graph. https://github.com/jesseduffield/lazygit/blob/5d30409f338d1edef18054a9b3c051a5fd92a20d/pkg/gui/presentation/commits.go#L80

ChrisMcD1 avatar May 12 '25 22:05 ChrisMcD1