[31929] branches/release_1_6/base/portmgr/dmg/postflight

jmpp at macports.org jmpp at macports.org
Tue Dec 11 23:20:28 PST 2007


Revision: 31929
          http://trac.macosforge.org/projects/macports/changeset/31929
Author:   jmpp at macports.org
Date:     2007-12-11 23:20:26 -0800 (Tue, 11 Dec 2007)

Log Message:
-----------
Provide more error redirection and reporting.

Modified Paths:
--------------
    branches/release_1_6/base/portmgr/dmg/postflight

Modified: branches/release_1_6/base/portmgr/dmg/postflight
===================================================================
--- branches/release_1_6/base/portmgr/dmg/postflight	2007-12-12 07:14:07 UTC (rev 31928)
+++ branches/release_1_6/base/portmgr/dmg/postflight	2007-12-12 07:20:26 UTC (rev 31929)
@@ -37,7 +37,7 @@
 BINPATH=$PREFIX/bin
 SBINPATH=$PREFIX/sbin
 MANPAGES=$PREFIX/share/man
-USHELL="$(basename "$SHELL")" || {
+USHELL="$(basename "$SHELL" 2>/dev/null)" || {
     echo "An attempt to determine your shell name failed! Please set your MacPorts compatible environment manually."
     exit 1
 }
@@ -93,7 +93,7 @@
             fi
             ;;
     esac
-    chown $USER $HOME/.$CONF_FILE
+    chown $USER $HOME/.$CONF_FILE || echo "Unable to switch your $HOME/.$CONF_FILE shell configuration file to your UID!"
     echo -e "# Finished adapting your $1 environment variable for use with MacPorts.\n" >> $HOME/.$CONF_FILE
 }
 
@@ -108,7 +108,7 @@
 fi
 
 # We gather the path into a variable of our own for faster operation:
-ORIGINAL_MANPATH="$($SHELL $LOGIN_FLAG -c "/usr/bin/printenv MANPATH")"
+ORIGINAL_MANPATH="$($SHELL $LOGIN_FLAG -c "/usr/bin/printenv MANPATH" 2>/dev/null)"
 # Adding out setting to the MANPATH variable only if it exists:
 if ! $SHELL $LOGIN_FLAG -c "/usr/bin/env | grep MANPATH" > /dev/null 2>&1 || \
 # and following that, if it's not empty:

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/macports-changes/attachments/20071211/a52bedf0/attachment.html


More information about the macports-changes mailing list