}
Config_System() {
- if [ "$UID" = "0" ]; then
+ if [ "$UID" = "0" -a -z "$I_local" ]; then
Msg "Starting system configuration:\n"
Msg " - bash shell:\n"
if [ -e /etc/bash.bashrc ]; then
else
Msg "Not running with root privileges - system configuration SKIPPED.\n"
grep "alex@barton.de" /etc/profile >/dev/null 2>&1
- if [ $? -ne 0 ]; then
+ if [ $? -ne 0 -o -n "$I_local" ]; then
Msg "Installing system files to $HOME/.etc/ ...\n"
mkdir -p "$HOME/.etc"
Copy_File sys/bashrc $HOME/.etc/bashrc "$user" 600
fi
}
+while [ $# -gt 0 ]; do
+ case "$1" in
+ "--local"|"-l")
+ export I_local=1; ;;
+ *)
+ echo "Usage: $0 [--local|-l]"
+ exit 1
+ esac
+ shift
+done
+
[ -n "$UID" ] || UID=`id -u`
export UID