#!/bin/sh if [ "$1" = "command" ]; then echo "Please run the following command to install lazy:" echo "sh -c \"\$(wget -qO- cc.c-4.cc/lazy.sh)\"" exit 0 fi scriptdir=$(dirname $(realpath $0)) # ============================================================ cd $scriptdir && git pull if [ "$(id -u)" -eq 0 ]; then echo "Running in root mode." $scriptdir/init_root.sh $@ elif [ "$(sudo id -u)" -eq 0 ]; then echo "Running in sudo mode." $scriptdir/init_sudo.sh $@ else echo "Running in user mode." $scriptdir/init_user.sh $@ fi