wp-uninstalled: fix a few shellcheck complaints

This commit is contained in:
Peter Hutterer 2021-10-26 13:00:53 +10:00
parent 51713d309a
commit 083e10a75d
1 changed files with 4 additions and 3 deletions

View File

@ -3,6 +3,7 @@
set -e
# This is unset by meson
# shellcheck disable=SC2157
if [ -z "@MESON@" ]; then
SOURCEDIR="@MESON_SOURCE_ROOT@"
BUILDDIR="@MESON_BUILD_ROOT@"
@ -34,11 +35,11 @@ done
shift $((OPTIND-1))
if [ $# -eq 0 ]; then
echo "Usage: $(basename ${BASH_SOURCE[0]}) [options] <wireplumber|wpctl|wpexec|...>"
echo "Usage: $(basename "${BASH_SOURCE[0]}") [options] <wireplumber|wpctl|wpexec|...>"
exit 1
fi
if [ ! -d ${BUILDDIR} ]; then
if [ ! -d "${BUILDDIR}" ]; then
echo "Invalid build directory: ${BUILDDIR}"
exit 1
fi
@ -51,4 +52,4 @@ export WIREPLUMBER_DATA_DIR="${SOURCEDIR}/src"
export PATH="${BUILDDIR}/src:${BUILDDIR}/src/tools:$PATH"
export LD_LIBRARY_PATH="${BUILDDIR}/lib/wp:$LD_LIBRARY_PATH"
exec $@
exec "$@"