git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: "Neal Kreitzinger" <neal@rsss.com>
To: git@vger.kernel.org
Subject: Re: git log missing last line of output
Date: Mon, 1 Jun 2009 15:50:27 -0500	[thread overview]
Message-ID: <h01enr$71i$1@ger.gmane.org> (raw)
In-Reply-To: 200905272106.31036.j6t@kdbg.org

Here is the summary I wrote up for my teammates:

Problem:  Git log does not display the last line of output.



Solution:

Linux uses a command called 'less' to control the pagination of command line 
output.  'less' is an enhanced version of the command 'more'.  For some 
reason, it is not compatible with SmarTerm when running the 'git log' 
command which causes the last line of output to be truncated.  Git log works 
fine when executed on the desktop command line using VNC.



Git has the option '--no-pager' to overcome incompatibility issues.  Since I 
do not know if the pager is having problems with any commands besides 'git 
log', I will focus on 'git log' only.  The command 'git --no-pager log' can 
be executed in lieu of 'git log' to display the log correctly.  A git alias 
can be setup to create a shorter command to accomplish this.  I've created 
the command 'git logr' as a system alias on the git testbox so you can use 
that command instead of 'git log'.  A system alias applies to all logins and 
repos on the system.



Add alias:

(Login root)

$ git config --system alias.logr '!git --no-pager log'

Note:  if you add an alias with the same name as a git command then git will 
ignore the alias.  If you create the above with the name 'log' then git will 
not run it even though the entry is in the config file.



View alias:

(Login user)

$ git config --system --list



Remove alias:

(Login root)

$ git config --system --unset alias.logr



Location:  /etc/gitconfig



Aliases can also be created to apply only to certain user logins or only to 
certain repos:



A global alias applies only to a specific user login and takes precedence 
over a system alias of the same name.

"global config file" location:

/home/userlogin/.gitconfig

command option:

"git config --global".  Run the option from the user login it applies to.



A file alias applies only to a specific repo and takes precedence over a 
global alias or a system alias of the same name.

"file config file" location:

/specific-repo/.git/config

command option:

"git config --file".  This is the default option so a plain "git config" is 
the same as "git config --file".  Run the option while in the pwd of the 
repo that it applies to.


v/r,
Neal

"Johannes Sixt" <j6t@kdbg.org> wrote in message 
news:200905272106.31036.j6t@kdbg.org...
> Please use "Reply to all" so that Cc list remains.
>
> On Mittwoch, 27. Mai 2009, Neal Kreitzinger wrote:
>> $ git log
>> commit 73170498d68a0011b37d7ee095bf88b8dcb6fbb5
>> Author: tstuser1 <tstuser1@tstuser.com>
>> Date:   Wed May 27 11:48:30 2009 -0500
>>
>>     2nd commit after initial commit
>>
>> commit 9f9ed5663d180caefd0bcaff4578fdb2c542bf17
>> Author: tstuser1 <tstuser1@tstuser.com>
>> Date:   Wed May 27 11:14:38 2009 -0500
>>
>>     1st commit after initial commit
>>
>> commit bee2e0fa066aaa9fed99c15c2ab58744a34fda48
>> Author: tstuser1 <tstuser1@tstuser.com>
>> Date:   Wed May 27 11:13:13 2009 -0500
>>
>> $
>> ***NOTE THAT LAST LINE OF OUTPUT IS MISSING ABOVE (SHOULD BE THE TITLE 
>> LINE
>> OF THE INITIAL COMMIT -- BUT ITS NOT THERE)***
>
> Please try
>
>   git --no-pager log
>
> Do you see the line? Yes? Then your pager and your terminal do not 
> cooperate
> correctly.
>
> -- Hannes 

  parent reply	other threads:[~2009-06-01 20:47 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-26 22:57 git log missing last line of output Neal Kreitzinger
2009-05-27 15:42 ` Michael J Gruber
2009-05-27 17:17   ` Neal Kreitzinger
2009-05-27 19:06     ` Johannes Sixt
2009-05-27 23:06       ` Neal Kreitzinger
2009-06-01 20:50       ` Neal Kreitzinger [this message]
2009-06-01 20:56         ` Brian Gernhardt

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='h01enr$71i$1@ger.gmane.org' \
    --to=neal@rsss.com \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).