Hi.
Patch removes hardcoded paths to echo and whoami in installation scripts.
Thanks.
Log()
{
- /bin/echo "$1" | tee -a $LOGFILE
+ echo "$1" | tee -a $LOGFILE
}
MakeTarball()
PLATFORM_SCRIPT_DIR=hp
fi
- if [ "$PLATFORM" = "aix" ];
- then
- USER=$(/bin/whoami)
- else
- USER=$(/usr/bin/whoami)
- fi
-
- if [ "$USER" != "root" ];
+ if [ $(whoami) != "root" ];
then
echo ""
echo "You should be root to run this script. Continuing anyway."
PLATFORM=hp-ux
fi
-if [ $PLATFORM = "aix" ];
-then
- USER=`/bin/whoami`
-else
- USER=`/usr/bin/whoami`
-fi
-
awkit() {
awk '
BEGIN {
}
# set permissions for non-links
if [ "${TYPE%link}" = "$TYPE" ]; then
- if [ "$USER" = "root" ]; then
+ if [ $(whoami) = "root" ]; then
chgrp $GROUP $DEST ||
echo "ERROR: \"chgrp $GROUP $DEST\" failed" >&2
chown $OWNER $DEST ||