* In-depth git blame? @ 2011-03-02 20:43 Jez 2011-03-02 21:15 ` Jeff King 0 siblings, 1 reply; 8+ messages in thread From: Jez @ 2011-03-02 20:43 UTC (permalink / raw) To: git Hi all, Git-blame is useful, but sometimes I want to know the series of commits that have affected a line -- not just the most recent one. Is there a way to do this? Regards, Jez ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: In-depth git blame? 2011-03-02 20:43 In-depth git blame? Jez @ 2011-03-02 21:15 ` Jeff King 2011-03-02 21:29 ` Peter Baumann 0 siblings, 1 reply; 8+ messages in thread From: Jeff King @ 2011-03-02 21:15 UTC (permalink / raw) To: Jez; +Cc: Thomas Rast, Bo Yang, git On Wed, Mar 02, 2011 at 03:43:42PM -0500, Jez wrote: > Git-blame is useful, but sometimes I want to know the series of > commits that have affected a line -- not just the most recent one. Is > there a way to do this? If you use "git gui blame" or "tig blame", both have a "blame from parent commit" feature. This restarts the blame using the content as it was just before the answer you just got, so you can recursively dig. It's unfortunately a somewhat manual process. There was a GSoC project to do what you asked, where you would indicate a set of lines and get a "git log"-like output of all the commits touching those lines. But there were some issues with the code, and it never quite made it upstream, I think. I'm not sure what the current status is. Cc'ing Thomas and Bo, who worked on it. -Peff ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: In-depth git blame? 2011-03-02 21:15 ` Jeff King @ 2011-03-02 21:29 ` Peter Baumann 2011-03-02 21:34 ` Jeff King 0 siblings, 1 reply; 8+ messages in thread From: Peter Baumann @ 2011-03-02 21:29 UTC (permalink / raw) To: Jeff King; +Cc: Jez, Thomas Rast, Bo Yang, git On Wed, Mar 02, 2011 at 04:15:45PM -0500, Jeff King wrote: > On Wed, Mar 02, 2011 at 03:43:42PM -0500, Jez wrote: > > > Git-blame is useful, but sometimes I want to know the series of > > commits that have affected a line -- not just the most recent one. Is > > there a way to do this? > > If you use "git gui blame" or "tig blame", both have a "blame from > parent commit" feature. This restarts the blame using the content as it > was just before the answer you just got, so you can recursively dig. > It's unfortunately a somewhat manual process. > Hm. I guess pressing 'B' will blame the parent commit in tig. But I can't figure out how to navigate back to the old commit (before pressing 'B')? Any hints appreciated! -Peter ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: In-depth git blame? 2011-03-02 21:29 ` Peter Baumann @ 2011-03-02 21:34 ` Jeff King 2011-03-02 21:44 ` Peter Baumann 0 siblings, 1 reply; 8+ messages in thread From: Jeff King @ 2011-03-02 21:34 UTC (permalink / raw) To: Peter Baumann; +Cc: Jez, Thomas Rast, Bo Yang, git On Wed, Mar 02, 2011 at 10:29:51PM +0100, Peter Baumann wrote: > > If you use "git gui blame" or "tig blame", both have a "blame from > > parent commit" feature. This restarts the blame using the content as > > it was just before the answer you just got, so you can recursively > > dig. It's unfortunately a somewhat manual process. > > > > Hm. I guess pressing 'B' will blame the parent commit in tig. But I > can't figure out how to navigate back to the old commit (before > pressing 'B')? Any hints appreciated! No, it is "," (comma) from the blame viewer in tig to blame starting from the parent of the blamed commit of the highlighted line. Doing "B" will just re-blame starting at that commit, which will of course give you the same answer (I think it is a global "go to blame view", so it is more useful when you are _not_ in the blame viewer already). And if you are confused at any point, "h" should give you a context-sensitive list of keystrokes. -Peff ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: In-depth git blame? 2011-03-02 21:34 ` Jeff King @ 2011-03-02 21:44 ` Peter Baumann 2011-03-02 21:50 ` Peter Baumann 2011-03-07 23:20 ` Jonas Fonseca 0 siblings, 2 replies; 8+ messages in thread From: Peter Baumann @ 2011-03-02 21:44 UTC (permalink / raw) To: Jeff King; +Cc: Jez, Thomas Rast, Bo Yang, Jonas Fonseca, git [ Cc Jonas, because he might know more about that ] On Wed, Mar 02, 2011 at 04:34:37PM -0500, Jeff King wrote: > On Wed, Mar 02, 2011 at 10:29:51PM +0100, Peter Baumann wrote: > > > > If you use "git gui blame" or "tig blame", both have a "blame from > > > parent commit" feature. This restarts the blame using the content as > > > it was just before the answer you just got, so you can recursively > > > dig. It's unfortunately a somewhat manual process. > > > > > > > Hm. I guess pressing 'B' will blame the parent commit in tig. But I > > can't figure out how to navigate back to the old commit (before > > pressing 'B')? Any hints appreciated! > > No, it is "," (comma) from the blame viewer in tig to blame starting > from the parent of the blamed commit of the highlighted line. > Thx, I didn't know that. Your help is really appreciated! > Doing "B" will just re-blame starting at that commit, which will of > course give you the same answer (I think it is a global "go to blame > view", so it is more useful when you are _not_ in the blame viewer > already). > > And if you are confused at any point, "h" should give you a > context-sensitive list of keystrokes. > Hm. I did look at the 'h'elp, but it wasn't mentioned there, at least not in my version (tig version 0.16-9-g7630a8f) here. > -Peff > -- > To unsubscribe from this list: send the line "unsubscribe git" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html > ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: In-depth git blame? 2011-03-02 21:44 ` Peter Baumann @ 2011-03-02 21:50 ` Peter Baumann 2011-03-07 23:20 ` Jonas Fonseca 1 sibling, 0 replies; 8+ messages in thread From: Peter Baumann @ 2011-03-02 21:50 UTC (permalink / raw) To: Jeff King; +Cc: Jez, Thomas Rast, Bo Yang, Jonas Fonseca, git On Wed, Mar 02, 2011 at 10:44:45PM +0100, Peter Baumann wrote: > [ Cc Jonas, because he might know more about that ] > > On Wed, Mar 02, 2011 at 04:34:37PM -0500, Jeff King wrote: > > On Wed, Mar 02, 2011 at 10:29:51PM +0100, Peter Baumann wrote: > > > > > > If you use "git gui blame" or "tig blame", both have a "blame from > > > > parent commit" feature. This restarts the blame using the content as > > > > it was just before the answer you just got, so you can recursively > > > > dig. It's unfortunately a somewhat manual process. > > > > > > > > > > Hm. I guess pressing 'B' will blame the parent commit in tig. But I > > > can't figure out how to navigate back to the old commit (before > > > pressing 'B')? Any hints appreciated! > > > > No, it is "," (comma) from the blame viewer in tig to blame starting > > from the parent of the blamed commit of the highlighted line. > > > Thx, I didn't know that. Your help is really appreciated! > > > Doing "B" will just re-blame starting at that commit, which will of > > course give you the same answer (I think it is a global "go to blame > > view", so it is more useful when you are _not_ in the blame viewer > > already). > > > > And if you are confused at any point, "h" should give you a > > context-sensitive list of keystrokes. > > > Hm. I did look at the 'h'elp, but it wasn't mentioned there, at least > not in my version (tig version 0.16-9-g7630a8f) here. > Ok. I take it back. I was blind not having it seen in the help. Searching for ',' did make me see it :-) -Peter ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: In-depth git blame? 2011-03-02 21:44 ` Peter Baumann 2011-03-02 21:50 ` Peter Baumann @ 2011-03-07 23:20 ` Jonas Fonseca 2011-03-08 6:48 ` Peter Baumann 1 sibling, 1 reply; 8+ messages in thread From: Jonas Fonseca @ 2011-03-07 23:20 UTC (permalink / raw) To: Peter Baumann; +Cc: Jeff King, Jez, Thomas Rast, Bo Yang, git On Wed, Mar 2, 2011 at 16:44, Peter Baumann <waste.manager@gmx.de> wrote: > [ Cc Jonas, because he might know more about that ] ... although he arrives late in the discussion. > On Wed, Mar 02, 2011 at 04:34:37PM -0500, Jeff King wrote: >> On Wed, Mar 02, 2011 at 10:29:51PM +0100, Peter Baumann wrote: >> >> > Hm. I guess pressing 'B' will blame the parent commit in tig. But I >> > can't figure out how to navigate back to the old commit (before >> > pressing 'B')? Any hints appreciated! >> >> No, it is "," (comma) from the blame viewer in tig to blame starting >> from the parent of the blamed commit of the highlighted line. >> > Thx, I didn't know that. Your help is really appreciated! Pressing 'B' in the blame view reloads the blame view based on the line/commit, which is currently selected. And as Jeff points out ',' reloads based on the parent of the current commit. Tig is very poor in terms of history (search, blame, commit) so there's is no 'back' button. -- Jonas Fonseca ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: In-depth git blame? 2011-03-07 23:20 ` Jonas Fonseca @ 2011-03-08 6:48 ` Peter Baumann 0 siblings, 0 replies; 8+ messages in thread From: Peter Baumann @ 2011-03-08 6:48 UTC (permalink / raw) To: Jonas Fonseca; +Cc: Jeff King, Jez, Thomas Rast, Bo Yang, git On Mon, Mar 07, 2011 at 06:20:56PM -0500, Jonas Fonseca wrote: > On Wed, Mar 2, 2011 at 16:44, Peter Baumann <waste.manager@gmx.de> wrote: > > [ Cc Jonas, because he might know more about that ] > > ... although he arrives late in the discussion. > > > On Wed, Mar 02, 2011 at 04:34:37PM -0500, Jeff King wrote: > >> On Wed, Mar 02, 2011 at 10:29:51PM +0100, Peter Baumann wrote: > >> > >> > Hm. I guess pressing 'B' will blame the parent commit in tig. But I > >> > can't figure out how to navigate back to the old commit (before > >> > pressing 'B')? Any hints appreciated! > >> > >> No, it is "," (comma) from the blame viewer in tig to blame starting > >> from the parent of the blamed commit of the highlighted line. > >> > > Thx, I didn't know that. Your help is really appreciated! > > Pressing 'B' in the blame view reloads the blame view based on the > line/commit, which is currently selected. And as Jeff points out ',' > reloads based on the parent of the current commit. > > Tig is very poor in terms of history (search, blame, commit) so > there's is no 'back' button. Ah. That explain I didn't find any. Thx. -Peter ^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2011-03-08 6:48 UTC | newest] Thread overview: 8+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2011-03-02 20:43 In-depth git blame? Jez 2011-03-02 21:15 ` Jeff King 2011-03-02 21:29 ` Peter Baumann 2011-03-02 21:34 ` Jeff King 2011-03-02 21:44 ` Peter Baumann 2011-03-02 21:50 ` Peter Baumann 2011-03-07 23:20 ` Jonas Fonseca 2011-03-08 6:48 ` Peter Baumann
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).