summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2007-04-14 19:22:49 +0000
committerZac Medico <zmedico@gentoo.org>2007-04-14 19:22:49 +0000
commitc14c076250b5123f52ca4fd64cc32dab7595adf1 (patch)
tree36ca232af35c6a2c373ca3ec8d6c0c098bdec681
parent56e8e6e653364e187f7e78c7349c9f9235bb6602 (diff)
downloadportage-c14c076250b5123f52ca4fd64cc32dab7595adf1.tar.gz
portage-c14c076250b5123f52ca4fd64cc32dab7595adf1.tar.bz2
portage-c14c076250b5123f52ca4fd64cc32dab7595adf1.zip
misc style fixes (trunk r6400:6401)
svn path=/main/branches/2.1.2/; revision=6405
-rwxr-xr-xbin/doins14
1 files changed, 7 insertions, 7 deletions
diff --git a/bin/doins b/bin/doins
index 43e3187cb..c0a495aef 100755
--- a/bin/doins
+++ b/bin/doins
@@ -1,24 +1,24 @@
#!/bin/bash
-# Copyright 1999-2006 Gentoo Foundation
+# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
source "${PORTAGE_BIN_PATH:-/usr/lib/portage/bin}"/isolated-functions.sh
if [ $# -lt 1 ] ; then
- echo "${0}: at least one argument needed"
+ echo "${0##*/}: at least one argument needed" 1>&2
exit 1
fi
-if [ "${1}" == "-r" ] ; then
+if [[ "$1" == "-r" ]] ; then
DOINSRECUR=y
shift
else
DOINSRECUR=n
fi
-[ -z "${INSDEPTH}" ] && declare -i INSDEPTH=0
-if [ ${INSDEPTH} -gt 30 ] ; then
- echo "${0}: sanity check ... 30 directories is too much :("
+[[ -z ${INSDEPTH} ]] && declare -i INSDEPTH=0
+if [[ ${INSDEPTH} -gt 30 ]] ; then
+ echo "${0##*/}: sanity check ... 30 directories is too much :(" 2>&1
exit 1
fi
@@ -30,7 +30,7 @@ if [[ ${INSDESTTREE#${D}} != "${INSDESTTREE}" ]]; then
exit 1
fi
-[ ! -d "${D}${INSDESTTREE}" ] && dodir "${INSDESTTREE}"
+[[ ! -d ${D}${INSDESTTREE} ]] && dodir "${INSDESTTREE}"
for x in "$@" ; do
if [ -L "$x" ] ; then