linuxbox/update_wrapper.sh

17 lines
297 B
Bash
Executable File

#!/bin/bash
# Update wrapper for code_server update script
if [ $EUID != 0 ]; then
sudo "$0" "$@"
fi
if [ ! -d ~/code_server ]; then
cd ~ &&
git clone https://git.cmtec.se/cm/code_server.git
fi
if [ -d ~/code_server ]; then
cd ~/code_server &&
git pull &&
./update.sh
fi