{"thread":{"id":"4017","subject":"git-bisect broken in 1.2.4","startedAt":"2006-05-01T18:10:20Z","lastAt":"2006-05-02T19:38:29Z","messageCount":6,"participants":["Olaf Hering","Uwe Zeisberger","Junio C Hamano","Johannes Schindelin"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"19331","messageId":"20060501181020.GA21263@suse.de","threadId":"4017","inReplyTo":null,"subject":"git-bisect broken in 1.2.4","fromName":"Olaf Hering","fromEmail":"olh@suse.de","sentAt":"2006-05-01T18:10:20Z","receivedAt":"2006-05-01T18:10:20Z","isPatch":false,"sender":{"key":"olh@suse.de","avatar":null},"body":"\nDid SuSE just pick up a bad version of git, 1.2.4?\ngit-bisect doesnt work correctly in the kernel sources, .git/HEAD doesnt\ncontain the commit id anymore, but 'ref: refs/heads/bisect'\n\nCONFIG_LOCALVERSION_AUTO depends on the id.\n"},{"id":"19346","messageId":"20060502070155.GA861@informatik.uni-freiburg.de","threadId":"4017","inReplyTo":"20060501181020.GA21263@suse.de","subject":"Re: git-bisect broken in 1.2.4","fromName":"Uwe Zeisberger","fromEmail":"zeisberg@informatik.uni-freiburg.de","sentAt":"2006-05-02T07:01:55Z","receivedAt":"2006-05-02T07:01:55Z","isPatch":false,"sender":{"key":"u.kleine-koenig@pengutronix.de","avatar":"https://gravatar.com/avatar/354b5e3ceb2806a2f1e1e382ac29ddbdad18288654da62b61eb13583a857eee7?d=mp&s=160"},"body":"Olaf Hering wrote:\n> Did SuSE just pick up a bad version of git, 1.2.4?\n> git-bisect doesnt work correctly in the kernel sources, .git/HEAD doesnt\n> contain the commit id anymore, but 'ref: refs/heads/bisect'\n> \n> CONFIG_LOCALVERSION_AUTO depends on the id.\nProbably you should update to at least linux-v2.6.15-g117a93d.  The\nscript to determine the localversion[1] depends on .git/HEAD being a\nsymlink.\n\nSince \n\n\tgit-1.1.4-g2fabd21\n\n.git/HEAD isn't a symlink any more (per default at least).\n\nYou can rebuild git with USE_SYMLINK_HEAD if you really want the old\nbehaviour.\n\nBest regards,\nUwe\n\n[1] scripts/setlocalversion\n\n-- \nUwe Zeisberger\n\nhttp://www.google.com/search?q=gigabyte+in+bit\n"},{"id":"19349","messageId":"7vpsiwopkv.fsf@assigned-by-dhcp.cox.net","threadId":"4017","inReplyTo":"20060502070155.GA861@informatik.uni-freiburg.de","subject":"Re: git-bisect broken in 1.2.4","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-05-02T07:25:52Z","receivedAt":"2006-05-02T07:25:52Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Uwe Zeisberger <zeisberg@informatik.uni-freiburg.de> writes:\n\n> Olaf Hering wrote:\n>> Did SuSE just pick up a bad version of git, 1.2.4?\n>> git-bisect doesnt work correctly in the kernel sources, .git/HEAD doesnt\n>> contain the commit id anymore, but 'ref: refs/heads/bisect'\n>> \n>> CONFIG_LOCALVERSION_AUTO depends on the id.\n> Probably you should update to at least linux-v2.6.15-g117a93d.  The\n> script to determine the localversion[1] depends on .git/HEAD being a\n> symlink.\n>\n> Since \n>\n> \tgit-1.1.4-g2fabd21\n>\n> .git/HEAD isn't a symlink any more (per default at least).\n\nOuch.  Although what Uwe says is all correct, we should not say\n\"don't try kernel older than 2615-117a\".  That makes bisect\nrather useless.\n\n> You can rebuild git with USE_SYMLINK_HEAD if you really want the old\n> behaviour.\n\nThat probably is a sane thing to do.\n\nWe should introduce prefer_symlink_refs configuration to work\nwith projects whose older version of build infrastructure\ndepends on symlink refs.\n\nThe patch is on top of post 1.3.1 git, but .c and .h part should\napply more-or-less cleanly to older code base.  You should \nbe able to say:\n\n\t[core]\n        prefersymlinkrefs = true\n\nin .git/config file, maybe do \"git checkout -f master\" to switch\nbranch and make .git/HEAD into symlink, and do the bisect again.\n\nSorry for the screwup.\n\n-- >8 --\n\ndiff --git a/Documentation/config.txt b/Documentation/config.txt\nindex b27b0d5..d1a4bec 100644\n--- a/Documentation/config.txt\n+++ b/Documentation/config.txt\n@@ -64,9 +64,11 @@ core.ignoreStat::\n \tslow, such as Microsoft Windows.  See gitlink:git-update-index[1].\n \tFalse by default.\n \n-core.onlyUseSymrefs::\n-\tAlways use the \"symref\" format instead of symbolic links for HEAD\n-\tand other symbolic reference files. True by default.\n+core.preferSymlinkRefs::\n+\tInstead of the default \"symref\" format for HEAD\n+\tand other symbolic reference files, use symbolic links.\n+\tThis is sometimes needed to work with old scripts that\n+\texpect HEAD to be a symbolic link.\n \n core.repositoryFormatVersion::\n \tInternal variable identifying the repository format and layout\ndiff --git a/Makefile b/Makefile\nindex 2374335..ecbdde6 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -28,8 +28,8 @@ # Define NO_STRCASESTR if you don't have\n #\n # Define NO_SETENV if you don't have setenv in the C library.\n #\n-# Define USE_SYMLINK_HEAD if you want .git/HEAD to be a symbolic link.\n-# Don't enable it on Windows.\n+# Define NO_SYMLINK_HEAD if you never want .git/HEAD to be a symbolic link.\n+# Enable it on Windows.  By default, symrefs are still used.\n #\n # Define PPC_SHA1 environment variable when running make to make use of\n # a bundled SHA1 routine optimized for PowerPC.\n@@ -265,6 +265,7 @@ ifeq ($(uname_O),Cygwin)\n \tNO_D_TYPE_IN_DIRENT = YesPlease\n \tNO_D_INO_IN_DIRENT = YesPlease\n \tNO_STRCASESTR = YesPlease\n+\tNO_SYMLINK_HEAD = YesPlease\n \tNEEDS_LIBICONV = YesPlease\n \t# There are conflicting reports about this.\n \t# On some boxes NO_MMAP is needed, and not so elsewhere.\n@@ -388,6 +389,9 @@ endif\n ifdef NO_D_INO_IN_DIRENT\n \tALL_CFLAGS += -DNO_D_INO_IN_DIRENT\n endif\n+ifdef NO_SYMLINK_HEAD\n+\tALL_CFLAGS += -DNO_SYMLINK_HEAD\n+endif\n ifdef NO_STRCASESTR\n \tCOMPAT_CFLAGS += -DNO_STRCASESTR\n \tCOMPAT_OBJS += compat/strcasestr.o\ndiff --git a/cache.h b/cache.h\nindex a0cf8ca..d186b44 100644\n--- a/cache.h\n+++ b/cache.h\n@@ -170,7 +170,7 @@ extern void rollback_index_file(struct c\n /* Environment bits from configuration mechanism */\n extern int trust_executable_bit;\n extern int assume_unchanged;\n-extern int only_use_symrefs;\n+extern int prefer_symlink_refs;\n extern int warn_ambiguous_refs;\n extern int diff_rename_limit_default;\n extern int shared_repository;\ndiff --git a/config.c b/config.c\nindex 4e1f0c2..6cd31a3 100644\n--- a/config.c\n+++ b/config.c\n@@ -227,8 +227,8 @@ int git_default_config(const char *var, \n \t\treturn 0;\n \t}\n \n-\tif (!strcmp(var, \"core.symrefsonly\")) {\n-\t\tonly_use_symrefs = git_config_bool(var, value);\n+\tif (!strcmp(var, \"core.prefersymlinkrefs\")) {\n+\t\tprefer_symlink_refs = git_config_bool(var, value);\n \t\treturn 0;\n \t}\n \ndiff --git a/environment.c b/environment.c\nindex 6df6478..444c99e 100644\n--- a/environment.c\n+++ b/environment.c\n@@ -13,7 +13,7 @@ char git_default_email[MAX_GITNAME];\n char git_default_name[MAX_GITNAME];\n int trust_executable_bit = 1;\n int assume_unchanged = 0;\n-int only_use_symrefs = 0;\n+int prefer_symlink_refs = 0;\n int warn_ambiguous_refs = 1;\n int repository_format_version = 0;\n char git_commit_encoding[MAX_ENCODING_LENGTH] = \"utf-8\";\ndiff --git a/refs.c b/refs.c\nindex 03398cc..275b914 100644\n--- a/refs.c\n+++ b/refs.c\n@@ -76,8 +76,8 @@ int create_symref(const char *git_HEAD, \n \tchar ref[1000];\n \tint fd, len, written;\n \n-#ifdef USE_SYMLINK_HEAD\n-\tif (!only_use_symrefs) {\n+#ifndef NO_SYMLINK_HEAD\n+\tif (prefer_symlink_refs) {\n \t\tunlink(git_HEAD);\n \t\tif (!symlink(refs_heads_master, git_HEAD))\n \t\t\treturn 0;\n"},{"id":"19350","messageId":"20060502073304.GA26111@suse.de","threadId":"4017","inReplyTo":"7vpsiwopkv.fsf@assigned-by-dhcp.cox.net","subject":"Re: git-bisect broken in 1.2.4","fromName":"Olaf Hering","fromEmail":"olh@suse.de","sentAt":"2006-05-02T07:33:04Z","receivedAt":"2006-05-02T07:33:04Z","isPatch":false,"sender":{"key":"olh@suse.de","avatar":null},"body":" On Tue, May 02, Junio C Hamano wrote:\n\n> Uwe Zeisberger <zeisberg@informatik.uni-freiburg.de> writes:\n> \n> > Olaf Hering wrote:\n> >> Did SuSE just pick up a bad version of git, 1.2.4?\n> >> git-bisect doesnt work correctly in the kernel sources, .git/HEAD doesnt\n> >> contain the commit id anymore, but 'ref: refs/heads/bisect'\n> >> \n> >> CONFIG_LOCALVERSION_AUTO depends on the id.\n> > Probably you should update to at least linux-v2.6.15-g117a93d.  The\n> > script to determine the localversion[1] depends on .git/HEAD being a\n> > symlink.\n> >\n> > Since \n> >\n> > \tgit-1.1.4-g2fabd21\n> >\n> > .git/HEAD isn't a symlink any more (per default at least).\n> \n> Ouch.  Although what Uwe says is all correct, we should not say\n> \"don't try kernel older than 2615-117a\".  That makes bisect\n> rather useless.\n> \n> > You can rebuild git with USE_SYMLINK_HEAD if you really want the old\n> > behaviour.\n> \n> That probably is a sane thing to do.\n\nOk, thanks for the patch.\nPetr, can you update our git package in time?\n"},{"id":"19361","messageId":"Pine.LNX.4.63.0605021241300.3795@wbgn013.biozentrum.uni-wuerzburg.de","threadId":"4017","inReplyTo":"7vpsiwopkv.fsf@assigned-by-dhcp.cox.net","subject":"Re: git-bisect broken in 1.2.4","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2006-05-02T10:42:52Z","receivedAt":"2006-05-02T10:42:52Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Tue, 2 May 2006, Junio C Hamano wrote:\n\n> Uwe Zeisberger <zeisberg@informatik.uni-freiburg.de> writes:\n> \n> > You can rebuild git with USE_SYMLINK_HEAD if you really want the old\n> > behaviour.\n> \n> That probably is a sane thing to do.\n> \n> We should introduce prefer_symlink_refs configuration to work\n> with projects whose older version of build infrastructure\n> depends on symlink refs.\n> \n> The patch is on top of post 1.3.1 git, but .c and .h part should\n> apply more-or-less cleanly to older code base.  You should \n> be able to say:\n> \n> \t[core]\n>         prefersymlinkrefs = true\n\nWhy not just use the existing method:\n\n\t[core]\n\t\tonlyusesymrefs = false\n\nHmm?\n\nCiao,\nDscho\n"},{"id":"19373","messageId":"Pine.LNX.4.63.0605022137290.21545@wbgn013.biozentrum.uni-wuerzburg.de","threadId":"4017","inReplyTo":"7vslnskzjj.fsf@assigned-by-dhcp.cox.net","subject":"Re: git-bisect broken in 1.2.4","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2006-05-02T19:38:29Z","receivedAt":"2006-05-02T19:38:29Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi\n\nOn Tue, 2 May 2006, Junio C Hamano wrote:\n\n> Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:\n> \n> > Why not just use the existing method:\n> >\n> > \t[core]\n> > \t\tonlyusesymrefs = false\n> \n> USE_SYMLINK_HEAD is not enabled by default, and when it is, it\n> _defaults_ to use symlink head.\n\nOkay. I missed the part that support is disabled by default.\n\nSorry for the noise,\nDscho\n"}]}