# and may source again at any time to change which installed TinyOS source
# tree their code shall be built against.
-TOSCFG=~/.tosrc
+TOSCFG="$HOME/.tosrc"
TOSBASE=/opt/tinyos
RCFILES="$HOME/.bashrc $HOME/.shrc $HOME/.kshrc $HOME/.cshrc $ENV"
fi
}
-# Update CLASSPATH by replacing the element value in $1 with the element value
+# Update CLASSPATH by replacing the element value in $1 with the element value
# in $2. An empty $2 removes element $1, if present. An empty $1, or $1 not
# present, adds $2.
updclasspath()
# Operations below here cannot be executed in a sub-shell
echo "tinyos: must be sourced"
elif [ "$1" = "-u" ]; then
- if [ -f $TOSCFG ]; then
+ if [ -f "$TOSCFG" ]; then
uninstallshrc
updclasspath "$TOSROOT" ""
unset TOSROOT TOSDIR MAKERULES
if [ -n "$1" ]; then
newroot=$(gettosroot "$1")
if [ -n "$newroot" ]; then
- echo "$TOSROOT" > "$TOSCFG"
+ echo "$newroot" > "$TOSCFG"
installshrc
echo "tinyos: now using $newroot"
else