[Bug?] git notes are not copied during rebase

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I am currently a heavy user of rebasing and noticed that my notes
don't get correctly applied, even if notes.rewrite.rebase is set
explicitly to true (though manual says that is the default).

Below is a use case that shows that a commit on a branch got rebased,
but the note was not copied to the new commit.

% mkdir notes
% cd notes
% git init
Initialized empty Git repository in /tmp/notes/.git/
% date
% git add a
% git commit -m c1
[master (root-commit) 2e24a91] c1
 1 file changed, 1 insertion(+)
 create mode 100644 a
% git checkout -b mybranch
Switched to a new branch 'mybranch'
% date
% git add b
% git commit -m c2
[mybranch 5ef9954] c2
 1 file changed, 1 insertion(+)
 create mode 100644 b
% git notes add -m note1
% git log
commit 5ef9954 (HEAD -> mybranch)
Author: Norbert Kiesel <nkiesel@xxxxxxxxxxxxxxxx>
Date:   Mon Nov 14 15:48:00 2016 -0800

    c2

Notes:
    note1

commit 2e24a91 (master)
Author: Norbert Kiesel <nkiesel@xxxxxxxxxxxxxxxx>
Date:   Mon Nov 14 15:48:00 2016 -0800

    c1
% git notes
c39895a0948c17df2028f07c3ec0993a532edabf
5ef9954dbadddfccefe95277be5e7a995335124b
% git checkout master
Switched to branch 'master'
% date
% git commit -a -m c3
[master 1368832] c3
 1 file changed, 1 insertion(+)
% git rebase master mybranch
First, rewinding head to replay your work on top of it...
Applying: c2
% git log
commit 8921cb7 (HEAD -> mybranch)
Author: Norbert Kiesel <nkiesel@xxxxxxxxxxxxxxxx>
Date:   Mon Nov 14 15:48:00 2016 -0800

    c2

commit 1368832 (master)
Author: Norbert Kiesel <nkiesel@xxxxxxxxxxxxxxxx>
Date:   Mon Nov 14 15:48:00 2016 -0800

    c3

commit 2e24a91
Author: Norbert Kiesel <nkiesel@xxxxxxxxxxxxxxxx>
Date:   Mon Nov 14 15:48:00 2016 -0800

    c1
% git notes
c39895a0948c17df2028f07c3ec0993a532edabf
5ef9954dbadddfccefe95277be5e7a995335124b



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]