Preinstall prompt more readable

This commit is contained in:
advplyr 2021-09-25 14:14:22 -05:00
parent cce860ff74
commit e2a6bf6c1a
2 changed files with 12 additions and 5 deletions

View File

@ -53,24 +53,30 @@ should_build_config() {
setup_config() {
if should_build_config; then
echo "Alright then, let's setup a new config."
echo "Okay, let's setup a new config."
AUDIOBOOK_PATH=""
read -p "Enter path for your audiobooks [Default: $DEFAULT_AUDIOBOOK_PATH]: " AUDIOBOOK_PATH
read -p "
Enter path for your audiobooks [Default: $DEFAULT_AUDIOBOOK_PATH]:
" AUDIOBOOK_PATH
if [[ -z "$AUDIOBOOK_PATH" ]]; then
AUDIOBOOK_PATH="$DEFAULT_AUDIOBOOK_PATH"
fi
DATA_PATH=""
read -p "Enter path for data files, i.e. streams, downloads, database [Default: $DEFAULT_DATA_PATH]: " DATA_PATH
read -p "
Enter path for data files, i.e. streams, downloads, database [Default: $DEFAULT_DATA_PATH]:
" DATA_PATH
if [[ -z "$DATA_PATH" ]]; then
DATA_PATH="$DEFAULT_DATA_PATH"
fi
PORT=""
read -p "Port for the web ui [Default: $DEFAULT_PORT]: " PORT
read -p "
Port for the web ui [Default: $DEFAULT_PORT]:
" PORT
if [[ -z "$PORT" ]]; then
PORT="$DEFAULT_PORT"

View File

@ -8,7 +8,7 @@ cd "$SCRIPT_DIR/.."
# Get package version without double quotes
VERSION="$( eval echo $( jq '.version' package.json) )"
OUTPUT_FILE="audiobookshelf_${VERSION}_amd64"
OUTPUT_FILE="audiobookshelf_${VERSION}_amd64.deb"
echo ">>> Building Client"
echo "--------------------"
@ -33,5 +33,6 @@ pkg -t node12-linux-x64 -o build/debian/usr/share/audiobookshelf/audiobookshelf
fakeroot dpkg-deb --build build/debian
mv build/debian.deb "build/$OUTPUT_FILE"
chmod +x "build/$OUTPUT_FILE"
echo "Finished! Filename: $OUTPUT_FILE"