13
0

Allow to skip installing 3rd party plugins

This commit is contained in:
Robin Gareus 2020-07-19 22:05:18 +02:00
parent 9d119b5ac5
commit 1421512510
Signed by: rgareus
GPG Key ID: A090BCE02CF57F04

View File

@ -63,6 +63,39 @@ VaildateYesNoQuestion ()
}
VaildateYesNoEnterQuestion ()
{
# $1 = Question Text
# $2 = default y/n
local INPUT_OK="n"
local USER_INPUT=""
local PRMT="[Y/n]"
local DFLT="y"
if [ "$2" = "n" ]; then
PRMT="[y/N]"
DFLT="n"
fi
until test "y" = $INPUT_OK; do
echo ""
read -p "$1 $PRMT: " USER_INPUT
echo ""
if [ -z $USER_INPUT ]; then
INPUT_OK="y"
USER_INPUT=$DFLT
else
if [ "Y" = $USER_INPUT -o "y" = $USER_INPUT -o "n" = $USER_INPUT -o "N" = $USER_INPUT ]; then
INPUT_OK="y"
fi
fi
done
echo $USER_INPUT | tr '[:upper:]' '[:lower:]'
}
SystemInstall ()
{
@ -668,6 +701,20 @@ else
echo "Can not create link because ${USER_BIN_DIR} does not exist"
fi
############################################
# Allow to remove non-free stuff for purists
############################################
if test "${PGM_VENDOR}" = "Ardour"; then
ANSWER=$(VaildateYesNoEnterQuestion "Install Harrison XT plugins?" "y")
if test "n" = $ANSWER; then
${SUPER} rm -rf "${INSTALL_DEST_BASE}/${PGM_FULL_NAME}/LV2/Harrison.lv2"
else
echo "Deploying Harrison plugins to ${INSTALL_DEST_BASE}/${PGM_FULL_NAME}/LV2/Harrison.lv2"
fi
fi
###########################
# Check Jack and qjackctl
###########################