setup with zenity
This commit is contained in:
34
setup.sh
34
setup.sh
@@ -1,7 +1,31 @@
|
||||
#!/bin/bash
|
||||
cd ~
|
||||
git clone https://git.keiran.us/keiran/steamdeck-scripts.git .keiran-sds
|
||||
if [ -d /home/deck/.keiran-sds ]; then
|
||||
if zenity --question --no-wrap --no-wrap \
|
||||
--text='Keiran Steam Deck Scripts is already installed. Re-install?'; then
|
||||
rm -rf /home/deck/.keiran-sds
|
||||
else
|
||||
echo canceled
|
||||
exit 0
|
||||
fi
|
||||
fi
|
||||
|
||||
coproc zenity --progress --auto-close --title='Installing' --text='Git cloning...'
|
||||
|
||||
cd /home/deck
|
||||
if ! git clone https://git.keiran.us/keiran/steamdeck-scripts.git .keiran-sds; then
|
||||
echo 100 >&${COPROC[1]}
|
||||
zenity --error --no-wrap --no-markup --text='failed to clone https://git.keiran.us/keiran/steamdeck-scripts'
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo 33 >&${COPROC[1]}
|
||||
echo '#Setting up virtual environment...' >&${COPROC[1]}
|
||||
python3 -m venv ~/.keiran-sds
|
||||
cd ~/.keiran-sds
|
||||
./bin/pip3 install --upgrade pip
|
||||
./bin/pip3 install -r requirements.txt
|
||||
/home/deck/.keiran-sds/bin/pip3 install --upgrade pip
|
||||
cd /home/deck/.keiran-sds
|
||||
|
||||
echo 67 >&${COPROC[1]}
|
||||
echo '#Installing dependencies...' >&${COPROC[1]}
|
||||
/home/deck/.keiran-sds/bin/pip3 install -r requirements.txt
|
||||
|
||||
echo 100 >&${COPROC[1]} # Close Zenity
|
||||
Reference in New Issue
Block a user