- Add '-d' option to disable sound.
This commit is contained in:
39
bin/run.sh
39
bin/run.sh
@@ -8,21 +8,32 @@ APPL_HOME_DIR="$(dirname "$(dirname "$0")")"
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
|
||||
if [[ "$1" == "-h" ]]
|
||||
then
|
||||
echo "usage: run.sh [-h] [-i] <Application_Dir> <Application_Exec> [Args...]"
|
||||
echo "with -i enabling internet access."
|
||||
|
||||
exit 0
|
||||
fi
|
||||
export APPL_NETWORK="no-internet"
|
||||
export PULSE_DISABLE_FLAG=""
|
||||
|
||||
if [[ "$1" == "-i" ]]
|
||||
then
|
||||
shift;
|
||||
export APPL_NETWORK="internet"
|
||||
else
|
||||
export APPL_NETWORK="no-internet"
|
||||
fi
|
||||
while [[ "$1" == "-h" || "$1" == "-d" || "$1" == "-i" ]]
|
||||
do
|
||||
if [[ "$1" == "-h" ]]
|
||||
then
|
||||
echo "usage: run.sh [-h] [-d] [-i] <Application_Dir> <Application_Exec> [Args...]"
|
||||
echo "with -d disabling sound,"
|
||||
echo "with -i enabling internet access."
|
||||
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [[ "$1" == "-d" ]]
|
||||
then
|
||||
shift;
|
||||
export PULSE_DISABLE_FLAG="-disabled"
|
||||
fi
|
||||
|
||||
if [[ "$1" == "-i" ]]
|
||||
then
|
||||
shift;
|
||||
export APPL_NETWORK="internet"
|
||||
fi
|
||||
done
|
||||
|
||||
export APPL_DIR="$1"
|
||||
shift
|
||||
|
||||
Reference in New Issue
Block a user