From 6cdbcfce77f3c4c3df76c73a2877ed5f7accf05b Mon Sep 17 00:00:00 2001 From: Mike Frysinger Date: Fri, 23 Dec 2005 00:35:38 +0000 Subject: colorize eclass/ebuilds as shellscripts #116419 by Rajiv Manglani. (Portage version: 2.0.53) --- sys-apps/less/files/code2color.patch | 9 +++++++++ sys-apps/less/files/lesspipe.sh | 4 ++-- 2 files changed, 11 insertions(+), 2 deletions(-) (limited to 'sys-apps/less') diff --git a/sys-apps/less/files/code2color.patch b/sys-apps/less/files/code2color.patch index d330623544bd..a841574f9894 100644 --- a/sys-apps/less/files/code2color.patch +++ b/sys-apps/less/files/code2color.patch @@ -8,3 +8,12 @@ return \$code; }; +@@ -3192,7 +3192,7 @@ + # + + $LANGUAGE{'shellscript'} = { +- 'filename' => '\\.(sh|shell)$', ++ 'filename' => '\\.(ebuild|eclass|sh|shell)$', + 'regex' => '^\\s*#\\s*![^\\s]*(sh|bash|ash|zsh|ksh)', + 'patterns' => [ { + 'name' => 'comment', diff --git a/sys-apps/less/files/lesspipe.sh b/sys-apps/less/files/lesspipe.sh index 6d014cd8ed62..629a15b30368 100644 --- a/sys-apps/less/files/lesspipe.sh +++ b/sys-apps/less/files/lesspipe.sh @@ -130,7 +130,7 @@ lesspipe() { *.awk|*.groff|*.java|*.js|*.m4|*.php|*.pl|*.pm|*.pod|*.sh|\ *.ad[asb]|*.asm|*.inc|*.[ch]|*.[ch]pp|*.[ch]xx|*.cc|*.hh|\ *.lsp|*.l|*.pas|*.p|*.xml|*.xps|*.xsl|*.axp|*.ppd|*.pov|\ - *.diff|*.patch|*.py|*.rb|*.sql) + *.diff|*.patch|*.py|*.rb|*.sql|*.ebuild|*.eclass) # Allow people to flip color off if they dont want it case ${LESSCOLOR} in @@ -185,7 +185,7 @@ if [[ -z $1 ]] ; then echo "Usage: lesspipe.sh " elif [[ $1 == "-V" ]] ; then Id="cvsid" - cvsid="$Id: lesspipe.sh,v 1.13 2005/11/26 00:32:53 vapier Exp $" + cvsid="$Id: lesspipe.sh,v 1.14 2005/12/23 00:35:38 vapier Exp $" cat <<-EOF $cvsid Copyright 2001-2005 Gentoo Foundation -- cgit v1.2.3-65-gdbad