summaryrefslogtreecommitdiffstats
path: root/device_cio_free
diff options
context:
space:
mode:
authorDan Horák <dan@danny.cz>2010-05-05 10:08:18 +0200
committerDan Horák <dan@danny.cz>2010-05-05 10:08:18 +0200
commitabbff789ae244412df43f14c5542eca8b6a8fc8d (patch)
treee88cb0ee2ee15ec694a27a9a535e4e1696cbcbb6 /device_cio_free
parent5f31c74b8a9c168a15db3704a387364c39429abc (diff)
downloadutils-abbff789ae244412df43f14c5542eca8b6a8fc8d.tar.gz
utils-abbff789ae244412df43f14c5542eca8b6a8fc8d.tar.xz
utils-abbff789ae244412df43f14c5542eca8b6a8fc8d.zip
switch from tr to sed
use sed for lowercase (and comma to space) substitutions because it lives in /bin while tr lives in /usr/bin and thus requires /usr to be mounted
Diffstat (limited to 'device_cio_free')
-rw-r--r--device_cio_free4
1 files changed, 2 insertions, 2 deletions
diff --git a/device_cio_free b/device_cio_free
index 381c0a0..80e9451 100644
--- a/device_cio_free
+++ b/device_cio_free
@@ -49,7 +49,7 @@ free_device()
[ -z "$1" ] && return
- DEV_LIST=$(echo "$1" | tr "A-Z" "a-z" | sed 's/,/ /g')
+ DEV_LIST=$(echo "$1" | sed 'y/ABCDEF/abcdef/' | sed 's/,/ /g')
for DEV in $DEV_LIST; do
[ $VERBOSE ] && echo "Freeing device(s) $DEV"
@@ -245,7 +245,7 @@ if [ $MODE_DASD ]; then
sed -e 's/.*[[:space:]]dasd=\([^[:space:]]*\).*/\1/' -e 's/([^)]*)//g' \
-e 's/nopav\|nofcx\|autodetect\|probeonly//g' -e 's/,,/,/g' -e 's/^,//' -e 's/,$//')
- for DEVRANGE in $(echo $DEVICES | tr ',' ' '); do
+ for DEVRANGE in $(echo $DEVICES | sed 's/,/ /g'); do
free_device $DEVRANGE
done
fi