install.sh: check if dependencies are installed
This commit is contained in:
parent
c73da12024
commit
4402e6b2e3
@ -5,6 +5,13 @@
|
||||
# - python3: check with `python3 --version`
|
||||
#- venv: check with `python3 -m venv --help`
|
||||
#
|
||||
# check dependencies
|
||||
set -e
|
||||
bash --version > /dev/null
|
||||
python3 --version > /dev/null
|
||||
python3 -m venv --help > /dev/null
|
||||
set +e
|
||||
#
|
||||
PREFIX="$HOME/.local"
|
||||
HELP="""
|
||||
$0: install pdf2book with its virtual environment
|
||||
@ -73,7 +80,7 @@ then
|
||||
then
|
||||
echo -n """Directory '$SRCDIR' already exist.
|
||||
Do you want to overwrite? [y/N] """
|
||||
read confirm && [[ $confirm == [yY] || $confirm == [yY][eE][sS] ]] || exit 1
|
||||
read confirm && [[ $confirm == [yY] || $confirm == [yY][eE][sS] ]] || echo "... exiting ..." && exit 1
|
||||
fi
|
||||
rm -rf $SRCDIR
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user