{"thread":{"id":"19517","subject":"git log missing last line of output","startedAt":"2009-05-26T22:57:07Z","lastAt":"2009-06-01T20:56:18Z","messageCount":7,"participants":["Neal Kreitzinger","Michael J Gruber","Johannes Sixt","Brian Gernhardt"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"114750","messageId":"gvhrtf$vpr$1@ger.gmane.org","threadId":"19517","inReplyTo":null,"subject":"git log missing last line of output","fromName":"Neal Kreitzinger","fromEmail":"neal@rsss.com","sentAt":"2009-05-26T22:57:07Z","receivedAt":"2009-05-26T22:57:07Z","isPatch":false,"sender":{"key":"neal@rsss.com","avatar":null},"body":"Git log is not displaying the last line of output (for a plain \"$ git log\" \nthe last line of output should be the title line of the initial commit). \n(I'm using git 1.5.5.6 on rhel 5.3.)  This missing last line also occurs \nwith \"git log --since\" in which the last line of output should be the title \nline of the first commit after the specified date, but it is missing in this \nscenario also.  I've searched the release notes for 1.5.6 thru 1.6.3.1 and \ndid not find this mentioned.  Does this also happen in newer versions of git \nafter 1.5.5.6?\n\nv/r,\nNeal \n"},{"id":"114807","messageId":"4A1D5F70.4030101@drmicha.warpmail.net","threadId":"19517","inReplyTo":"gvhrtf$vpr$1@ger.gmane.org","subject":"Re: git log missing last line of output","fromName":"Michael J Gruber","fromEmail":"git@drmicha.warpmail.net","sentAt":"2009-05-27T15:42:40Z","receivedAt":"2009-05-27T15:42:40Z","isPatch":false,"sender":{"key":"git@grubix.eu","avatar":"https://avatars.githubusercontent.com/u/233215?v=4"},"body":"Neal Kreitzinger venit, vidit, dixit 27.05.2009 00:57:\n> Git log is not displaying the last line of output (for a plain \"$ git log\" \n> the last line of output should be the title line of the initial commit). \n\nIt should be the last line of the commit message, which is the \"title\nline\" (subject) if and only if the message consists of the subject line\nonly.\n\n> (I'm using git 1.5.5.6 on rhel 5.3.)  This missing last line also occurs \n> with \"git log --since\" in which the last line of output should be the title \n> line of the first commit after the specified date, but it is missing in this \n> scenario also.  I've searched the release notes for 1.5.6 thru 1.6.3.1 and \n> did not find this mentioned.  Does this also happen in newer versions of git \n> after 1.5.5.6?\n\nI can't reproduce this with git 1.5.5.6 (vanilla, not rhel). Do you have\na minimal reproducible test case?\n\nMichael\n"},{"id":"114814","messageId":"gvjsc9$f40$1@ger.gmane.org","threadId":"19517","inReplyTo":"4A1D5F70.4030101@drmicha.warpmail.net","subject":"Re: git log missing last line of output","fromName":"Neal Kreitzinger","fromEmail":"neal@rsss.com","sentAt":"2009-05-27T17:17:09Z","receivedAt":"2009-05-27T17:17:09Z","isPatch":false,"sender":{"key":"neal@rsss.com","avatar":null},"body":"Here is a 'copy and paste' of a testcase scenario that I recreated/executed \nin response to your reply (with comments added):\n\n***CREATE NEW PROJECT SOURCE***\n$ mkdir tstcase1\n$ cd tstcase1\n$ vi file1\n$ cat file1\ntest1\n***MAKE IT A GIT REPO***\n$ git config --global user.name 'tstuser1'\n$ git config --global user.name 'tstuser1@tstuser.com'\n$ git config --list\nuser.name=tstuser1\nuser.email=tstuser1@tstuser.com\n$ git init\nInitialized empty Git repository in .git/\n$ git add .\n$ git status\n# On branch master\n#\n# Initial commit\n#\n# Changes to be committed:\n#   (use \"git rm --cached <file>...\" to unstage)\n#\n#       new file: file1\n#\n***INITIAL COMMIT***\n$ git commit\n\ninitial commit\n# Please enter the commit message for your changes.\n# (Comment lines starting with '#' will not be included)\n# On branch master\n#\n# Initial commit\n#\n# Changes to be committed:\n#   (use \"git rm --cached <file>...\" to unstage)\n#\n#       new file: file1\n#\n~\n~\n~\n~\n~\n~\n~\n~\n~\n~\n~\n\".git/COMMIT_EDITMSG\" 12L, 262C written\nCreated initial commit bee2e0f: initial commit\n 1 files changed, 1 insertions(+), 0 deletions(-)\n create mode 100644 file1\n***FIRST MODIFICATION TO REPO***\n$ vi file1\n$ cat file1\ntest1 mod1\n$ git add file1\n$ git status\n# On branch master\n# Changes to be committed:\n#   (use \"git reset HEAD <file>...\" to unstage)\n#\n#       modified:   file1\n#\n***FIRST COMMIT AFTER INITIAL COMMIT***\n$ git commit\n\n1st commit after initial commit\n# Please enter the commit message for your changes.\n# (Comment lines starting with '#' will not be included)\n# On branch master\n# Changes to be committed:\n#   (use \"git reset HEAD <file>...\" to unstage)\n#\n#       modified:   file1\n#\n~\n~\n~\n~\n~\n~\n~\n~\n~\n~\n~\n~\n~\n~\n\".git/COMMIT_EDITMSG\" 9L, 259C written\nCreated commit 9f9ed56: 1st commit after initial commit\n 1 files changed, 1 insertions(+), 1 deletions(-)\n***MODIFY THE REPO AGAIN FOR GOOD MEASURE***\n$ vi file1\n$ cat file1\ntest1 mod2\n$ git add file1\n$ git status\n# On branch master\n# Changes to be committed:\n#   (use \"git reset HEAD <file>...\" to unstage)\n#\n#       modified:   file1\n#\n***SECOND COMMIT AFTER INITIAL COMMIT***\n$ git commit\n\n2nd commit after initial commit\n# Please enter the commit message for your changes.\n# (Comment lines starting with '#' will not be included)\n# On branch master\n# Changes to be committed:\n#   (use \"git reset HEAD <file>...\" to unstage)\n#\n#       modified:   file1\n#\n~\n~\n~\n~\n~\n~\n~\n~\n~\n~\n~\n~\n~\n~\n\".git/COMMIT_EDITMSG\" 9L, 259C written\nCreated commit 7317049: 2nd commit after initial commit\n 1 files changed, 1 insertions(+), 1 deletions(-)\n$ clear\n\n***EXECUTE GIT LOG***\n$ git log\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\ncommit 73170498d68a0011b37d7ee095bf88b8dcb6fbb5\nAuthor: tstuser1 <tstuser1@tstuser.com>\nDate:   Wed May 27 11:48:30 2009 -0500\n\n    2nd commit after initial commit\n\ncommit 9f9ed5663d180caefd0bcaff4578fdb2c542bf17\nAuthor: tstuser1 <tstuser1@tstuser.com>\nDate:   Wed May 27 11:14:38 2009 -0500\n\n    1st commit after initial commit\n\ncommit bee2e0fa066aaa9fed99c15c2ab58744a34fda48\nAuthor: tstuser1 <tstuser1@tstuser.com>\nDate:   Wed May 27 11:13:13 2009 -0500\n\n$\n***NOTE THAT LAST LINE OF OUTPUT IS MISSING ABOVE (SHOULD BE THE TITLE LINE \nOF THE INITIAL COMMIT -- BUT ITS NOT THERE)***\n$ clear\n***GIT LOG LAST TWO COMMITS***\n$ git log -2\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\ncommit 73170498d68a0011b37d7ee095bf88b8dcb6fbb5\nAuthor: tstuser1 <tstuser1@tstuser.com>\nDate:   Wed May 27 11:48:30 2009 -0500\n\n    2nd commit after initial commit\n\ncommit 9f9ed5663d180caefd0bcaff4578fdb2c542bf17\nAuthor: tstuser1 <tstuser1@tstuser.com>\nDate:   Wed May 27 11:14:38 2009 -0500\n\n$\n***NOTE THAT THE LAST LINE OF OUTPUT IS MISSING (SHOULD BE THE TITLE LINE OF \nTHE 1ST COMMIT AFTER INITIAL COMMIT -- BUT ITS NOT THERE)***\n$ clear\n***GIT LOG LAST COMMIT***\n$ git log -1\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\ncommit 73170498d68a0011b37d7ee095bf88b8dcb6fbb5\nAuthor: tstuser1 <tstuser1@tstuser.com>\nDate:   Wed May 27 11:48:30 2009 -0500\n\n$\n***NOTE THAT LAST LINE OF OUTPUT IS MISSING (SHOULD BE THE TITLE LINE OF THE \nLAST COMMIT -- BUT ITS NOT THERE)***\n\nIs this the kind of testcase that you are looking for?\n\n\nv/r,\nNeal\n\n\"Michael J Gruber\" <git@drmicha.warpmail.net> wrote in message \nnews:4A1D5F70.4030101@drmicha.warpmail.net...\n> Neal Kreitzinger venit, vidit, dixit 27.05.2009 00:57:\n>> Git log is not displaying the last line of output (for a plain \"$ git \n>> log\"\n>> the last line of output should be the title line of the initial commit).\n>\n> It should be the last line of the commit message, which is the \"title\n> line\" (subject) if and only if the message consists of the subject line\n> only.\n>\n>> (I'm using git 1.5.5.6 on rhel 5.3.)  This missing last line also occurs\n>> with \"git log --since\" in which the last line of output should be the \n>> title\n>> line of the first commit after the specified date, but it is missing in \n>> this\n>> scenario also.  I've searched the release notes for 1.5.6 thru 1.6.3.1 \n>> and\n>> did not find this mentioned.  Does this also happen in newer versions of \n>> git\n>> after 1.5.5.6?\n>\n> I can't reproduce this with git 1.5.5.6 (vanilla, not rhel). Do you have\n> a minimal reproducible test case?\n>\n> Michael \n"},{"id":"114827","messageId":"200905272106.31036.j6t@kdbg.org","threadId":"19517","inReplyTo":"gvjsc9$f40$1@ger.gmane.org","subject":"Re: git log missing last line of output","fromName":"Johannes Sixt","fromEmail":"j6t@kdbg.org","sentAt":"2009-05-27T19:06:30Z","receivedAt":"2009-05-27T19:06:30Z","isPatch":false,"sender":{"key":"j6t@kdbg.org","avatar":"https://avatars.githubusercontent.com/u/14810926?v=4"},"body":"Please use \"Reply to all\" so that Cc list remains.\n\nOn Mittwoch, 27. Mai 2009, Neal Kreitzinger wrote:\n> $ git log\n> commit 73170498d68a0011b37d7ee095bf88b8dcb6fbb5\n> Author: tstuser1 <tstuser1@tstuser.com>\n> Date:   Wed May 27 11:48:30 2009 -0500\n>\n>     2nd commit after initial commit\n>\n> commit 9f9ed5663d180caefd0bcaff4578fdb2c542bf17\n> Author: tstuser1 <tstuser1@tstuser.com>\n> Date:   Wed May 27 11:14:38 2009 -0500\n>\n>     1st commit after initial commit\n>\n> commit bee2e0fa066aaa9fed99c15c2ab58744a34fda48\n> Author: tstuser1 <tstuser1@tstuser.com>\n> Date:   Wed May 27 11:13:13 2009 -0500\n>\n> $\n> ***NOTE THAT LAST LINE OF OUTPUT IS MISSING ABOVE (SHOULD BE THE TITLE LINE\n> OF THE INITIAL COMMIT -- BUT ITS NOT THERE)***\n\nPlease try\n\n   git --no-pager log\n\nDo you see the line? Yes? Then your pager and your terminal do not cooperate \ncorrectly.\n\n-- Hannes\n"},{"id":"114860","messageId":"gvkgrs$hs8$1@ger.gmane.org","threadId":"19517","inReplyTo":"200905272106.31036.j6t@kdbg.org","subject":"Re: git log missing last line of output","fromName":"Neal Kreitzinger","fromEmail":"neal@rsss.com","sentAt":"2009-05-27T23:06:50Z","receivedAt":"2009-05-27T23:06:50Z","isPatch":false,"sender":{"key":"neal@rsss.com","avatar":null},"body":"$ git --no-pager log\n\n...does display the last line of output.  (The missing last line occurs in \nthe SmarTerm terminal emulator.)\n\n$ git log\n\n...does display the last line of output on the same server's desktop when \nconnecting via VNC.\n\nThanks for the help.  (Not sure how to 'reply to all' in Outlook newsreader. \nIt only has 'reply to group' and 'reply to sender' options...)\n\nNeal\n\n\"Johannes Sixt\" <j6t@kdbg.org> wrote in message \nnews:200905272106.31036.j6t@kdbg.org...\n> Please use \"Reply to all\" so that Cc list remains.\n>\n> On Mittwoch, 27. Mai 2009, Neal Kreitzinger wrote:\n>> $ git log\n>> commit 73170498d68a0011b37d7ee095bf88b8dcb6fbb5\n>> Author: tstuser1 <tstuser1@tstuser.com>\n>> Date:   Wed May 27 11:48:30 2009 -0500\n>>\n>>     2nd commit after initial commit\n>>\n>> commit 9f9ed5663d180caefd0bcaff4578fdb2c542bf17\n>> Author: tstuser1 <tstuser1@tstuser.com>\n>> Date:   Wed May 27 11:14:38 2009 -0500\n>>\n>>     1st commit after initial commit\n>>\n>> commit bee2e0fa066aaa9fed99c15c2ab58744a34fda48\n>> Author: tstuser1 <tstuser1@tstuser.com>\n>> Date:   Wed May 27 11:13:13 2009 -0500\n>>\n>> $\n>> ***NOTE THAT LAST LINE OF OUTPUT IS MISSING ABOVE (SHOULD BE THE TITLE \n>> LINE\n>> OF THE INITIAL COMMIT -- BUT ITS NOT THERE)***\n>\n> Please try\n>\n>   git --no-pager log\n>\n> Do you see the line? Yes? Then your pager and your terminal do not \n> cooperate\n> correctly.\n>\n> -- Hannes \n"},{"id":"115213","messageId":"h01enr$71i$1@ger.gmane.org","threadId":"19517","inReplyTo":"200905272106.31036.j6t@kdbg.org","subject":"Re: git log missing last line of output","fromName":"Neal Kreitzinger","fromEmail":"neal@rsss.com","sentAt":"2009-06-01T20:50:27Z","receivedAt":"2009-06-01T20:50:27Z","isPatch":false,"sender":{"key":"neal@rsss.com","avatar":null},"body":"Here is the summary I wrote up for my teammates:\n\nProblem:  Git log does not display the last line of output.\n\n\n\nSolution:\n\nLinux uses a command called 'less' to control the pagination of command line \noutput.  'less' is an enhanced version of the command 'more'.  For some \nreason, it is not compatible with SmarTerm when running the 'git log' \ncommand which causes the last line of output to be truncated.  Git log works \nfine when executed on the desktop command line using VNC.\n\n\n\nGit has the option '--no-pager' to overcome incompatibility issues.  Since I \ndo not know if the pager is having problems with any commands besides 'git \nlog', I will focus on 'git log' only.  The command 'git --no-pager log' can \nbe executed in lieu of 'git log' to display the log correctly.  A git alias \ncan be setup to create a shorter command to accomplish this.  I've created \nthe command 'git logr' as a system alias on the git testbox so you can use \nthat command instead of 'git log'.  A system alias applies to all logins and \nrepos on the system.\n\n\n\nAdd alias:\n\n(Login root)\n\n$ git config --system alias.logr '!git --no-pager log'\n\nNote:  if you add an alias with the same name as a git command then git will \nignore the alias.  If you create the above with the name 'log' then git will \nnot run it even though the entry is in the config file.\n\n\n\nView alias:\n\n(Login user)\n\n$ git config --system --list\n\n\n\nRemove alias:\n\n(Login root)\n\n$ git config --system --unset alias.logr\n\n\n\nLocation:  /etc/gitconfig\n\n\n\nAliases can also be created to apply only to certain user logins or only to \ncertain repos:\n\n\n\nA global alias applies only to a specific user login and takes precedence \nover a system alias of the same name.\n\n\"global config file\" location:\n\n/home/userlogin/.gitconfig\n\ncommand option:\n\n\"git config --global\".  Run the option from the user login it applies to.\n\n\n\nA file alias applies only to a specific repo and takes precedence over a \nglobal alias or a system alias of the same name.\n\n\"file config file\" location:\n\n/specific-repo/.git/config\n\ncommand option:\n\n\"git config --file\".  This is the default option so a plain \"git config\" is \nthe same as \"git config --file\".  Run the option while in the pwd of the \nrepo that it applies to.\n\n\nv/r,\nNeal\n\n\"Johannes Sixt\" <j6t@kdbg.org> wrote in message \nnews:200905272106.31036.j6t@kdbg.org...\n> Please use \"Reply to all\" so that Cc list remains.\n>\n> On Mittwoch, 27. Mai 2009, Neal Kreitzinger wrote:\n>> $ git log\n>> commit 73170498d68a0011b37d7ee095bf88b8dcb6fbb5\n>> Author: tstuser1 <tstuser1@tstuser.com>\n>> Date:   Wed May 27 11:48:30 2009 -0500\n>>\n>>     2nd commit after initial commit\n>>\n>> commit 9f9ed5663d180caefd0bcaff4578fdb2c542bf17\n>> Author: tstuser1 <tstuser1@tstuser.com>\n>> Date:   Wed May 27 11:14:38 2009 -0500\n>>\n>>     1st commit after initial commit\n>>\n>> commit bee2e0fa066aaa9fed99c15c2ab58744a34fda48\n>> Author: tstuser1 <tstuser1@tstuser.com>\n>> Date:   Wed May 27 11:13:13 2009 -0500\n>>\n>> $\n>> ***NOTE THAT LAST LINE OF OUTPUT IS MISSING ABOVE (SHOULD BE THE TITLE \n>> LINE\n>> OF THE INITIAL COMMIT -- BUT ITS NOT THERE)***\n>\n> Please try\n>\n>   git --no-pager log\n>\n> Do you see the line? Yes? Then your pager and your terminal do not \n> cooperate\n> correctly.\n>\n> -- Hannes \n"},{"id":"115214","messageId":"DD9E6A72-B168-424E-8406-483B1F315088@silverinsanity.com","threadId":"19517","inReplyTo":"h01enr$71i$1@ger.gmane.org","subject":"Re: git log missing last line of output","fromName":"Brian Gernhardt","fromEmail":"benji@silverinsanity.com","sentAt":"2009-06-01T20:56:18Z","receivedAt":"2009-06-01T20:56:18Z","isPatch":false,"sender":{"key":"benji@silverinsanity.com","avatar":"https://gravatar.com/avatar/e06c101dbc25c68114d859b4a9ec7cf8a2c52fd2b0270ef0eac0e2e63ff22311?d=mp&s=160"},"body":"\nOn Jun 1, 2009, at 4:50 PM, Neal Kreitzinger wrote:\n\n> Git has the option '--no-pager' to overcome incompatibility issues.   \n> Since I\n> do not know if the pager is having problems with any commands  \n> besides 'git\n> log', I will focus on 'git log' only.  The command 'git --no-pager  \n> log' can\n> be executed in lieu of 'git log' to display the log correctly.  A  \n> git alias\n> can be setup to create a shorter command to accomplish this.  I've  \n> created\n> the command 'git logr' as a system alias on the git testbox so you  \n> can use\n> that command instead of 'git log'.  A system alias applies to all  \n> logins and\n> repos on the system.\n\nYou could also use the core.pager and/or pager.<cmd> configuration  \nvariables.  Setting either to \"false\" or \"no\" (or \"off\" in git >=  \n1.6.3-rc1) will stop git from using the pager without needing an  \nalias.  See git-config(1) (or Documentation/config.txt) for details.\n\n~~ Brian\n"}]}