From: Mike Frysinger Date: Tue, 21 Jan 2014 01:32:23 +0000 (-0500) Subject: gentoo: update keyword helpers X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=6d0816bf9242d25d37056e84bdd212aec1042784;p=home.git gentoo: update keyword helpers --- diff --git a/.profile.d/gentoo.sh b/.profile.d/gentoo.sh index 24e10ad..1f1de40 100644 --- a/.profile.d/gentoo.sh +++ b/.profile.d/gentoo.sh @@ -1,5 +1,6 @@ alias ebuild-sync='rsync -av ./ /usr/portage/${PWD#/usr/local/src/gentoo-x86/} --exclude ChangeLog --exclude CVS --exclude metadata.xml --delete' alias ebuild-emerge='sudo emerge -1av $(echo ${PWD} | awk -F/ "{printf \"%s/%s\", \$(NF-1), \$(NF)}")' +alias ekeyword='ekeyword -v -q' cvs_gentoo_url() { _cvs_gentoo_url() { @@ -209,11 +210,10 @@ eskeys() { # running in a category rather than package cat="/" fi - [[ -z $* ]] && set -- arm m68k s390 sh + [[ -z $* ]] && set -- m68k s390 sh for k in "$@" ; do - local list="$(grep "^KEYWORDS=.*~${k}\>.*[^~]x86" *${cat}*d -l)" + local list="$(grep "^[[:space:]]*KEYWORDS=.*~${k}\>.*[^~]x86" *${cat}*d -l)" [[ -z ${list} ]] && continue - sed -i "1s:.*:# Copyright 1999-$(date +%Y) Gentoo Foundation:" ${list} ekeyword ${k} ${list} done }