* git log --graph and root commits
@ 2009-02-13 4:16 Sitaram Chamarty
2009-02-13 11:41 ` Johannes Schindelin
0 siblings, 1 reply; 5+ messages in thread
From: Sitaram Chamarty @ 2009-02-13 4:16 UTC (permalink / raw)
To: git
I was wondering if there was any way, when using 'git log
--graph --pretty=oneline' to get a different marker (perhaps
an underscore) for a root commit.
I have a couple of repos in which there are multiple roots
(a bit like the git tree itself, which has separately rooted
html and man branches), and it would be nice to see some
sign of that break in the git log graph.
Thanks,
Sitaram
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: git log --graph and root commits
2009-02-13 4:16 git log --graph and root commits Sitaram Chamarty
@ 2009-02-13 11:41 ` Johannes Schindelin
2009-02-13 14:56 ` Sitaram Chamarty
0 siblings, 1 reply; 5+ messages in thread
From: Johannes Schindelin @ 2009-02-13 11:41 UTC (permalink / raw)
To: Sitaram Chamarty; +Cc: git
Hi,
On Fri, 13 Feb 2009, Sitaram Chamarty wrote:
> I was wondering if there was any way, when using 'git log
> --graph --pretty=oneline' to get a different marker (perhaps
> an underscore) for a root commit.
Is it not enough that the line ends? That is a pretty obvious visual
marker for me that this is a root commit. But I see that you are _asking_
for the lines not to be shown, by using --pretty=oneline.
You might be interested in this instead:
git log --graph --pretty=format:'%h %s%n'
Hth,
Dscho
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: git log --graph and root commits
2009-02-13 11:41 ` Johannes Schindelin
@ 2009-02-13 14:56 ` Sitaram Chamarty
2009-02-13 16:39 ` Jakub Narebski
0 siblings, 1 reply; 5+ messages in thread
From: Sitaram Chamarty @ 2009-02-13 14:56 UTC (permalink / raw)
To: git
On 2009-02-13, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:
> On Fri, 13 Feb 2009, Sitaram Chamarty wrote:
>> I was wondering if there was any way, when using 'git log
>> --graph --pretty=oneline' to get a different marker (perhaps
>> an underscore) for a root commit.
> Is it not enough that the line ends? That is a pretty obvious visual
> marker for me that this is a root commit. But I see that you are _asking_
> for the lines not to be shown, by using --pretty=oneline.
Yes; I'm short on vertical space here.
> You might be interested in this instead:
>
> git log --graph --pretty=format:'%h %s%n'
It doubles the height requirement, but you gave me an idea:
git log --graph --pretty=tformat:'%h <%p> %s' --all |
perl -pe '$_.="----\n" if /<>/; s/<.*?> //'
Thanks for pointing me in the right direction.
Regards,
Sitaram
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: git log --graph and root commits
2009-02-13 14:56 ` Sitaram Chamarty
@ 2009-02-13 16:39 ` Jakub Narebski
2009-02-14 0:40 ` Sitaram Chamarty
0 siblings, 1 reply; 5+ messages in thread
From: Jakub Narebski @ 2009-02-13 16:39 UTC (permalink / raw)
To: Sitaram Chamarty; +Cc: git
Sitaram Chamarty <sitaramc@gmail.com> writes:
> On 2009-02-13, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:
>> On Fri, 13 Feb 2009, Sitaram Chamarty wrote:
>
>>> I was wondering if there was any way, when using 'git log
>>> --graph --pretty=oneline' to get a different marker (perhaps
>>> an underscore) for a root commit.
>>
>> You might be interested in this instead:
>>
>> git log --graph --pretty=format:'%h %s%n'
>
> It doubles the height requirement, but you gave me an idea:
>
> git log --graph --pretty=tformat:'%h <%p> %s' --all |
> perl -pe '$_.="----\n" if /<>/; s/<.*?> //'
>
> Thanks for pointing me in the right direction.
Gaaah... I tried running it on git.git :-))))
--
Jakub Narebski
Poland
ShadeHawk on #git
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: git log --graph and root commits
2009-02-13 16:39 ` Jakub Narebski
@ 2009-02-14 0:40 ` Sitaram Chamarty
0 siblings, 0 replies; 5+ messages in thread
From: Sitaram Chamarty @ 2009-02-14 0:40 UTC (permalink / raw)
To: git
On 2009-02-13, Jakub Narebski <jnareb@gmail.com> wrote:
> Sitaram Chamarty <sitaramc@gmail.com> writes:
>> On 2009-02-13, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:
>>> git log --graph --pretty=format:'%h %s%n'
>> It doubles the height requirement, but you gave me an idea:
>>
>> git log --graph --pretty=tformat:'%h <%p> %s' --all |
>> perl -pe '$_.="----\n" if /<>/; s/<.*?> //'
>>
>> Thanks for pointing me in the right direction.
>
> Gaaah... I tried running it on git.git :-))))
:-)
Seriously, I find 'log --graph' is useful on projects where
not everyone is an expert and things might go a little
haywire here and there. People merge the wrong thing with
the wrong other thing, maybe, and you want to see how
precisely they got there.
A project managed by git.gods can become a lot more complex
and not have to actually care about this visualisation.
Of course, gitk is really good and manages a lot more
complexity, obviously, but I like 'log --graph' also. And
I've sort of fallen in love with --simplify-by-decoration
too. Very cool stuff.
The things you can do on an xterm...!
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2009-02-14 0:42 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-02-13 4:16 git log --graph and root commits Sitaram Chamarty
2009-02-13 11:41 ` Johannes Schindelin
2009-02-13 14:56 ` Sitaram Chamarty
2009-02-13 16:39 ` Jakub Narebski
2009-02-14 0:40 ` Sitaram Chamarty
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).