* [feature request] find git commit log before rebase
@ 2016-05-26 16:55 ryenus
2016-05-26 20:37 ` Sebastian Staudt
[not found] ` <CA+xP2SYXUCfLHcyfQu6SLhZ6jRptp3gK0myatKVUxyP-2B=dPQ@mail.gmail.com>
0 siblings, 2 replies; 3+ messages in thread
From: ryenus @ 2016-05-26 16:55 UTC (permalink / raw)
To: git
Assuming I have branches master (m), and a side branch (b), with a
history tree like below:
m0 --- m1 -- m2 -- m3 -- m4 --- master (m)
\ / \
b1 ------ b2 b3 -- b4 -- branch (b) (HEAD)
|
(tag:POINT_BEFORE_REBASE)
The history of branch b is can be described as:
1. branch b is forked at point of m1
2. branch b is merged to master into m3,
3. branch b then is rebased (fast-forward) from b2 to m4
4. then branch b started its new life as b3 b4 after rebase
With the following command: I can find b3 and b4 since last fork-point
git log --oneline $(git merge-base --fork-point master)..b
But how to find out commits b1 b2, given the fact that b2 is the point
before rebase?
I understand it can be achieved via:
git log --oneline m2..b2
That's because I know b2 is the point before rebase,
and m2 is another child of the subsequent merge commit m3
I wonder how to do this with an simple (enough) command without me
looking through the history and find b2 and m2 manually?
Thanks!
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [feature request] find git commit log before rebase
2016-05-26 16:55 [feature request] find git commit log before rebase ryenus
@ 2016-05-26 20:37 ` Sebastian Staudt
[not found] ` <CA+xP2SYXUCfLHcyfQu6SLhZ6jRptp3gK0myatKVUxyP-2B=dPQ@mail.gmail.com>
1 sibling, 0 replies; 3+ messages in thread
From: Sebastian Staudt @ 2016-05-26 20:37 UTC (permalink / raw)
To: ryenus; +Cc: git
Hi.
I think what you want is `git reflog` (http://git-scm.com/man/reflog).
git reflog b
Will tell you the commits b pointed to in the past.
Best regards,
Sebastian
2016-05-26 18:55 GMT+02:00 ryenus <ryenus@gmail.com>:
> Assuming I have branches master (m), and a side branch (b), with a
> history tree like below:
>
> m0 --- m1 -- m2 -- m3 -- m4 --- master (m)
> \ / \
> b1 ------ b2 b3 -- b4 -- branch (b) (HEAD)
> |
> (tag:POINT_BEFORE_REBASE)
>
> The history of branch b is can be described as:
>
> 1. branch b is forked at point of m1
> 2. branch b is merged to master into m3,
> 3. branch b then is rebased (fast-forward) from b2 to m4
> 4. then branch b started its new life as b3 b4 after rebase
>
> With the following command: I can find b3 and b4 since last fork-point
>
> git log --oneline $(git merge-base --fork-point master)..b
>
> But how to find out commits b1 b2, given the fact that b2 is the point
> before rebase?
>
> I understand it can be achieved via:
>
> git log --oneline m2..b2
>
> That's because I know b2 is the point before rebase,
> and m2 is another child of the subsequent merge commit m3
>
> I wonder how to do this with an simple (enough) command without me
> looking through the history and find b2 and m2 manually?
>
> Thanks!
> --
> 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] 3+ messages in thread
* Re: [feature request] find git commit log before rebase
[not found] ` <CA+xP2SYXUCfLHcyfQu6SLhZ6jRptp3gK0myatKVUxyP-2B=dPQ@mail.gmail.com>
@ 2016-05-27 2:57 ` ryenus
0 siblings, 0 replies; 3+ messages in thread
From: ryenus @ 2016-05-27 2:57 UTC (permalink / raw)
To: Sebastian Staudt; +Cc: git
Indeed, specifying the branch name does the trick
and this works with `git reflog` and/or `git log --walk-reflogs`
Thank you very much!
On 27 May 2016 at 01:58, Sebastian Staudt <koraktor@gmail.com> wrote:
> Hi.
>
> I think what you want is `git reflog` (http://git-scm.com/man/reflog).
>
> git reflog b
>
> Will tell you the commits b pointed to in the past.
>
> Best regards,
> Sebastian
> ryenus <ryenus@gmail.com> schrieb am Do., 26. Mai 2016 um 19:03:
>>
>> Assuming I have branches master (m), and a side branch (b), with a
>> history tree like below:
>>
>> m0 --- m1 -- m2 -- m3 -- m4 --- master (m)
>> \ / \
>> b1 ------ b2 b3 -- b4 -- branch (b) (HEAD)
>> |
>> (tag:POINT_BEFORE_REBASE)
>>
>> The history of branch b is can be described as:
>>
>> 1. branch b is forked at point of m1
>> 2. branch b is merged to master into m3,
>> 3. branch b then is rebased (fast-forward) from b2 to m4
>> 4. then branch b started its new life as b3 b4 after rebase
>>
>> With the following command: I can find b3 and b4 since last fork-point
>>
>> git log --oneline $(git merge-base --fork-point master)..b
>>
>> But how to find out commits b1 b2, given the fact that b2 is the point
>> before rebase?
>>
>> I understand it can be achieved via:
>>
>> git log --oneline m2..b2
>>
>> That's because I know b2 is the point before rebase,
>> and m2 is another child of the subsequent merge commit m3
>>
>> I wonder how to do this with an simple (enough) command without me
>> looking through the history and find b2 and m2 manually?
>>
>> Thanks!
>> --
>> 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] 3+ messages in thread
end of thread, other threads:[~2016-05-27 2:58 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-05-26 16:55 [feature request] find git commit log before rebase ryenus
2016-05-26 20:37 ` Sebastian Staudt
[not found] ` <CA+xP2SYXUCfLHcyfQu6SLhZ6jRptp3gK0myatKVUxyP-2B=dPQ@mail.gmail.com>
2016-05-27 2:57 ` ryenus
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.