summaryrefslogtreecommitdiffstats
path: root/bin/doinfo
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2007-01-11 18:50:51 +0000
committerMike Frysinger <vapier@gentoo.org>2007-01-11 18:50:51 +0000
commit71a41f72cc38e646ed2945f4c7b343a60247d968 (patch)
tree55ef76b63b008882005facc90084df255a80e4b5 /bin/doinfo
parent912ffed14090eb8659c9850dc52a88038e960293 (diff)
downloadportage-71a41f72cc38e646ed2945f4c7b343a60247d968.tar.gz
portage-71a41f72cc38e646ed2945f4c7b343a60247d968.tar.bz2
portage-71a41f72cc38e646ed2945f4c7b343a60247d968.zip
add support for user-customizable compression #9870
svn path=/main/trunk/; revision=5555
Diffstat (limited to 'bin/doinfo')
-rwxr-xr-xbin/doinfo20
1 files changed, 7 insertions, 13 deletions
diff --git a/bin/doinfo b/bin/doinfo
index 82db070b8..7e1dd30ca 100755
--- a/bin/doinfo
+++ b/bin/doinfo
@@ -1,21 +1,15 @@
#!/bin/bash
-# Copyright 1999-2006 Gentoo Foundation
+# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
-if [ ${#} -lt 1 ] ; then
- echo "doinfo: at least one argument needed"
+if [[ -z $1 ]] ; then
+ vecho "${0##*/}: at least one argument needed"
exit 1
fi
-if [ ! -d "${D}usr/share/info" ] ; then
- install -d "${D}usr/share/info"
+
+if [[ ! -d ${D}usr/share/info ]] ; then
+ install -d "${D}usr/share/info" || exit 1
fi
-for x in "$@" ; do
- if [ -e "${x}" ] ; then
- install -m0644 "${x}" "${D}usr/share/info"
- gzip -f -9 "${D}usr/share/info/${x##*/}"
- else
- echo "doinfo: ${x} does not exist"
- fi
-done
+exec install -m0644 "$@" "${D}usr/share/info"