Commit graph

6 commits

Author SHA1 Message Date
Johannes Schindelin cd112cef99 diff options: add --color
This patch is a slightly adjusted version of Junio's patch:
http://www.gelato.unsw.edu.au/archives/git/0604/19354.html

However, instead of using a config variable, this patch makes it available
as a diff option.

Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-06-17 17:08:16 -07:00
Junio C Hamano 285755127a Merge branch 'fix'
* fix:
  git-log produces no output
2006-04-21 13:14:30 -07:00
Linus Torvalds 34fd1c9ac5 git-log produces no output
When $PAGER is set to 'less -i', we used to fail because we
assumed the $PAGER is a command and simply exec'ed it.

Try exec first, and then run it through shell if it fails.  This
allows even funkier PAGERs like these ;-):

	PAGER='sed -e "s/^/`date`: /" | more'
	PAGER='contrib/colordiff.perl | less -RS'

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-21 13:00:10 -07:00
Junio C Hamano caef71a535 Do not fork PAGER=cat
Unless the user has a nonstandard "cat" command that does not
meow like a cat, this should not break anything and would save an
extra pipe.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-16 01:46:08 -07:00
Johannes Schindelin 402461aab1 pager: do not fork a pager if PAGER is set to empty.
This skips an extra pipe, and helps debugging tremendously.

[jc: PAGER=cat is a questionable hack and should be done as a separate
patch. ]

Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-04-16 01:40:04 -07:00
Linus Torvalds f67b45f862 Introduce trivial new pager.c helper infrastructure
This introduces the new function

	void setup_pager(void);

to set up output to be written through a pager applocation.

All in preparation for doing the simple scripts in C.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-02-28 14:49:32 -08:00