{"thread":{"id":"7263","subject":"Merging on a dirty tree???","startedAt":"2007-03-16T03:59:53Z","lastAt":"2007-03-16T10:53:29Z","messageCount":3,"participants":["Dmitry Torokhov","Santi Béjar","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"37198","messageId":"200703152359.53543.dtor@insightbb.com","threadId":"7263","inReplyTo":null,"subject":"Merging on a dirty tree???","fromName":"Dmitry Torokhov","fromEmail":"dtor@insightbb.com","sentAt":"2007-03-16T03:59:53Z","receivedAt":"2007-03-16T03:59:53Z","isPatch":false,"sender":{"key":"dtor@insightbb.com","avatar":null},"body":"Hi,\n\nI just tried to pull from Linus' tree into my local tree and it seems\nthat fast forward was committed even though the tree was dirty:\n\n...\ndrivers/media/video/cx88/cx88-input.c: needs update\ndrivers/media/video/ir-kbd-i2c.c: needs update\ndrivers/media/video/saa7134/saa7134-input.c: needs update\ninclude/linux/device.h: needs update\ninclude/linux/input.h: needs update\nfatal: Entry 'drivers/base/core.c' not uptodate. Cannot merge.\n Makefile                                |    4 +-\n arch/i386/kernel/nmi.c                  |    8 ----\n arch/x86_64/kernel/nmi.c                |    5 +--\n drivers/base/core.c                     |   29 ++++++++++++++\n drivers/hid/hid-core.c                  |   20 ++++-----\n drivers/net/natsemi.c                   |   58 +++++++++++++++-------------\n drivers/net/netxen/netxen_nic.h         |    1 +\n drivers/net/netxen/netxen_nic_ethtool.c |    1 +\n drivers/net/netxen/netxen_nic_hw.c      |    5 ++-\n drivers/net/netxen/netxen_nic_init.c    |   11 ++++-\n drivers/net/skge.c                      |   28 ++++++++-----\n drivers/s390/cio/ccwgroup.c             |   18 +++++++-\n drivers/scsi/scsi_sysfs.c               |   14 ++++++-\n fs/sysfs/file.c                         |   64 ++++++++++++++++++++++++++++--\n fs/sysfs/inode.c                        |   10 +++-\n include/asm-i386/nmi.h                  |    2 +-\n include/asm-x86_64/nmi.h                |    2 +-\n include/linux/device.h                  |    2 +\n include/linux/sysfs.h                   |    9 ++++\n 19 files changed, 211 insertions(+), 80 deletions(-)\n[dtor@anvil work]$ git --version\ngit version 1.5.0.3.438.gc49b2\n\nIt used to refuse merge if there were conflicts...\n\n-- \nDmitry\n"},{"id":"37225","messageId":"87slc54gb2.fsf@gmail.com","threadId":"7263","inReplyTo":"200703152359.53543.dtor@insightbb.com","subject":"Re: Merging on a dirty tree???","fromName":"Santi Béjar","fromEmail":"sbejar@gmail.com","sentAt":"2007-03-16T10:46:09Z","receivedAt":"2007-03-16T10:46:09Z","isPatch":false,"sender":{"key":"santi@agolina.net","avatar":null},"body":"Dmitry Torokhov <dtor@insightbb.com> writes:\n\n> Hi,\n>\n> I just tried to pull from Linus' tree into my local tree and it seems\n> that fast forward was committed even though the tree was dirty:\n\n[...]\n\n>  19 files changed, 211 insertions(+), 80 deletions(-)\n> [dtor@anvil work]$ git --version\n> git version 1.5.0.3.438.gc49b2\n>\n> It used to refuse merge if there were conflicts...\n\nTry with this patch.\n\nSanti\n\n-- >8 --\nFrom: \"Santi Béjar\" <sbejar@gmail.com>\nSubject: [PATCH] git-merge: finish when git-read-tree fails\n\nThe message formating (commit v1.5.0.3-28-gbe242d5) broke the && chain.\n\nNoticed by Dmitry Torokhov.\n\nSigned-off-by: Santi Béjar <sbejar@gmail.com>\n---\n git-merge.sh |    4 ++--\n 1 files changed, 2 insertions(+), 2 deletions(-)\n\ndiff --git a/git-merge.sh b/git-merge.sh\nindex 6ce62c8..8759c5a 100755\n--- a/git-merge.sh\n+++ b/git-merge.sh\n@@ -292,13 +292,13 @@ f,*)\n \t# Again the most common case of merging one remote.\n \techo \"Updating $(git-rev-parse --short $head)..$(git-rev-parse --short $1)\"\n \tgit-update-index --refresh 2>/dev/null\n-\tnew_head=$(git-rev-parse --verify \"$1^0\") &&\n-\tgit-read-tree -v -m -u --exclude-per-directory=.gitignore $head \"$new_head\" &&\n \tmsg=\"Fast forward\"\n \tif test -n \"$have_message\"\n \tthen\n \t\tmsg=\"$msg (no commit created; -m option ignored)\"\n \tfi\n+\tnew_head=$(git-rev-parse --verify \"$1^0\") &&\n+\tgit-read-tree -v -m -u --exclude-per-directory=.gitignore $head \"$new_head\" &&\n \tfinish \"$new_head\" \"$msg\" || exit\n \tdropsave\n \texit 0\n-- \n1.5.0.4.1010.g688e\n"},{"id":"37226","messageId":"7vd539v4ra.fsf@assigned-by-dhcp.cox.net","threadId":"7263","inReplyTo":"87slc54gb2.fsf@gmail.com","subject":"Re: Merging on a dirty tree???","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2007-03-16T10:53:29Z","receivedAt":"2007-03-16T10:53:29Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Santi Béjar <sbejar@gmail.com> writes:\n\n> From: \"Santi Béjar\" <sbejar@gmail.com>\n> Subject: [PATCH] git-merge: finish when git-read-tree fails\n>\n> The message formating (commit v1.5.0.3-28-gbe242d5) broke the && chain.\n>\n> Noticed by Dmitry Torokhov.\n>\n> Signed-off-by: Santi Béjar <sbejar@gmail.com>\n\nGaah.  Thanks, well spotted.\n\nThat makes v1.5.0.4 a dud.\n"}]}