Only delete contents of $CPOLIS_PATH

This commit is contained in:
Jason Streifling 2024-08-18 17:06:49 +02:00
parent 9ddd8198ee
commit 8d2944d00c

View File

@ -11,7 +11,7 @@ SYSTEMD_USER_DIR=$HOME/.config/systemd/user
! which tar >/dev/null 2>&1 && echo "tar needs to be installed" >&2 && exit 1
! which xargs >/dev/null 2>&1 && echo "xargs needs to be installed" >&2 && exit 1
rm -fr $CPOLIS_PATH
rm -fr $CPOLIS_PATH/*
latest_release=$(curl -s $CPOLIS_REPO_URL | jq -r '.[0].tag_name')
curl -Lo /tmp/cpolis.tar.gz https://git.streifling.com/jason/cpolis/archive/$latest_release.tar.gz
tar -xzf /tmp/cpolis.tar.gz -C $CPOLIS_PATH