{"thread":{"id":"6995","subject":"Funny reflog has missing space","startedAt":"2007-02-27T15:29:11Z","lastAt":"2007-02-28T09:34:51Z","messageCount":5,"participants":["Andy Parkins","Johannes Schindelin","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"35626","messageId":"200702271529.13258.andyparkins@gmail.com","threadId":"6995","inReplyTo":null,"subject":"Funny reflog has missing space","fromName":"Andy Parkins","fromEmail":"andyparkins@gmail.com","sentAt":"2007-02-27T15:29:11Z","receivedAt":"2007-02-27T15:29:11Z","isPatch":false,"sender":{"key":"andyparkins@gmail.com","avatar":null},"body":"Hello,\n\nI've just peeked in my reflog (tail .git/logs/HEAD), and found something \nstrange:\n\n72160ca5c05fab4fbd3c24c9b13cbd0651b60532 \nca7b20e2677960cfc52c525b8f8bdf12ce79176b Andy Parkins <long@emailaddress.com> \n1172589175 +0000commit: Log message goes here\n\nNotice that there is no space between the \"+0000\" and the \"commit\".  This is \ntrue for every item in this log and every log in this repository.\n\nOver in another part of the forest, I've got my git repository.  This is fine, \nand has the space where I would expect.  The only difference I can see is \nthat in one I'm using my long work email address, and in the git one I'm \nusing my shorter gmail address.\n\nIs this normal?  \"git-reflog show\" works fine in both cases.\n\n\n\nAndy\n-- \nDr Andy Parkins, M Eng (hons), MIET\nandyparkins@gmail.com\n"},{"id":"35633","messageId":"Pine.LNX.4.63.0702271659260.22628@wbgn013.biozentrum.uni-wuerzburg.de","threadId":"6995","inReplyTo":"200702271529.13258.andyparkins@gmail.com","subject":"Re: Funny reflog has missing space","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2007-02-27T15:59:57Z","receivedAt":"2007-02-27T15:59:57Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Tue, 27 Feb 2007, Andy Parkins wrote:\n\n> Is this normal?  \"git-reflog show\" works fine in both cases.\n\nYes, because Junio made me change the code to not barf on a missing space.\n\nThanks Junio,\nDscho\n"},{"id":"35651","messageId":"7v4pp7flew.fsf@assigned-by-dhcp.cox.net","threadId":"6995","inReplyTo":"200702271529.13258.andyparkins@gmail.com","subject":"Re: Funny reflog has missing space","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2007-02-27T19:30:31Z","receivedAt":"2007-02-27T19:30:31Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Andy Parkins <andyparkins@gmail.com> writes:\n\n> Hello,\n>\n> I've just peeked in my reflog (tail .git/logs/HEAD), and found something \n> strange:\n>\n> 72160ca5c05fab4fbd3c24c9b13cbd0651b60532 \n> ca7b20e2677960cfc52c525b8f8bdf12ce79176b Andy Parkins <long@emailaddress.com> \n> 1172589175 +0000commit: Log message goes here\n>\n> Notice that there is no space between the \"+0000\" and the \"commit\".  This is \n> true for every item in this log and every log in this repository.\n>\n> Over in another part of the forest, I've got my git repository.  This is fine, \n> and has the space where I would expect.  The only difference I can see is \n> that in one I'm using my long work email address, and in the git one I'm \n> using my shorter gmail address.\n>\n> Is this normal?  \"git-reflog show\" works fine in both cases.\n\nIt is not.  It would be good to find out who puts corrupted\nentry.\n"},{"id":"35669","messageId":"7vslcrcpeg.fsf@assigned-by-dhcp.cox.net","threadId":"6995","inReplyTo":"7v4pp7flew.fsf@assigned-by-dhcp.cox.net","subject":"Re: Funny reflog has missing space","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2007-02-27T20:32:39Z","receivedAt":"2007-02-27T20:32:39Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Junio C Hamano <junkio@cox.net> writes:\n\n> Andy Parkins <andyparkins@gmail.com> writes:\n>\n>> Hello,\n>>\n>> I've just peeked in my reflog (tail .git/logs/HEAD), and found something \n>> strange:\n>>\n>> 72160ca5c05fab4fbd3c24c9b13cbd0651b60532 \n>> ca7b20e2677960cfc52c525b8f8bdf12ce79176b Andy Parkins <long@emailaddress.com> \n>> 1172589175 +0000commit: Log message goes here\n>>\n>> Notice that there is no space between the \"+0000\" and the \"commit\".\n>> ...\n>> Is this normal?  \"git-reflog show\" works fine in both cases.\n>\n> It is not.  It would be good to find out who puts corrupted\n> entry.\n\nHmmm.  I am puzzled.  The only two low-level locations I know of\nthat writes into reflog are:\n\n * builtin-reflog.c::expire_reflog_ent() copies existing log\n   entry, which are parsed out, after reformatting it.  It has\n   an explicit \"\\t\" in the format string, so it is not it.\n\n * refs.c::log_ref_write() gets an optional log message and\n   writes it after the GMT offset, with an explicit \"\\t\", so\n   this is not it, either.\n"},{"id":"35790","messageId":"200702280934.52650.andyparkins@gmail.com","threadId":"6995","inReplyTo":"7vslcrcpeg.fsf@assigned-by-dhcp.cox.net","subject":"OT: Funny tab behaviour on terminals","fromName":"Andy Parkins","fromEmail":"andyparkins@gmail.com","sentAt":"2007-02-28T09:34:51Z","receivedAt":"2007-02-28T09:34:51Z","isPatch":false,"sender":{"key":"andyparkins@gmail.com","avatar":null},"body":"On Tuesday 2007 February 27 20:32, Junio C Hamano wrote:\n\n>  * refs.c::log_ref_write() gets an optional log message and\n>    writes it after the GMT offset, with an explicit \"\\t\", so\n>    this is not it, either.\n\nYour mention of tabs set off alarm bells in my head.  I had another look at \nthe files with \"less -S\" instead of tail and lo-and-behold, the tab is shown.\n\nPanic over.  This isn't a fault with git.  Stop reading now if you're only \ninterested in git.\n\nIt's some weird interaction with tabs and my terminal and those particular \nline lengths.  The two repositories I was comparing logs in have different \nemail addresses for me, so the column at which the tab activates is \ndifferent.  Bizarrely, in one case the tab appears swallowed, in the other it \nappeared correctly.\n\n-- time passes ---\n\nIt seems like a fault in terminals in general to me (perhaps it's specified in \na standard somewhere, so everyone just implements it):  if a tab is output in \nthe last column of the terminal, it's just swallowed - no space at all is \nshown.\n\nIt's easily repeatable.\n * Open an xterm\n * Resize it so that it's 50 columns wide.\n * echo -e \"0xxxxxxxxx1xxxxxxxxx2xxxxxxxxx3xxxxxxxxx4xxxxxxxx\\t5xxxxxxxxx\"\n * Notice that the \"5\" is not on the next line where one might expect, but is\n   in column 49\n\nAm I wrong to think this is wrong?  I've always thought that there was an \nimplicit tab just off the end of a terminal line, which effectively brings \nthe output to the next tab stop (i.e. column 0 of the next line).\n\n\nAndy\n\n-- \nDr Andy Parkins, M Eng (hons), MIET\nandyparkins@gmail.com\n"}]}