Thank you everyone.This is the solution which solved all my problems su - user -c '(cd $VARIABLE ; ... )' the single quotes delay the substitution from the outer shell, so it works in the subshell. Since $VARIABLE isn't set in the environment from which su - is run, what gets passed to cd is the empty string. Using single quotes, the '$VARIABLE' remains intact and gets the substitution when su __________________________________ Do you Yahoo!? New and Improved Yahoo! Mail - Send 10MB messages! http://promotions.yahoo.com/new_mail _______________________________________________ sunmanagers mailing list sunmanagers@sunmanagers.org http://www.sunmanagers.org/mailman/listinfo/sunmanagersReceived on Wed Aug 4 17:16:05 2004
This archive was generated by hypermail 2.1.8 : Thu Mar 03 2016 - 06:43:36 EST