From de5de8ff386e9221cfe23a7869762e386ae50270 Mon Sep 17 00:00:00 2001 From: Scarsz Date: Thu, 18 Jun 2015 15:21:50 -0700 Subject: [PATCH] Encapsulate service name in quotations --- functions/fn_start | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/functions/fn_start b/functions/fn_start index f4d13b45c..d6a25819b 100644 --- a/functions/fn_start +++ b/functions/fn_start @@ -114,7 +114,7 @@ fi # Create lock file date > "${rootdir}/${lockselfname}" cd "${executabledir}" -tmux new-session -d -s ${servicename} "${executable} ${parms}" 2> "${scriptlogdir}/.${servicename}-tmux-error.tmp" +tmux new-session -d -s "${servicename}" "${executable} ${parms}" 2> "${scriptlogdir}/.${servicename}-tmux-error.tmp" # tmux pipe-pane not supported in tmux versions < 1.6 if [ "$(tmux -V|sed "s/tmux //"|sed -n '1 p'|tr -cd [:digit:])" -lt "16" ]; then echo "Console logging disabled: Tmux => 1.6 required" >> "${consolelog}" @@ -124,7 +124,7 @@ elif [ "$(tmux -V|sed "s/tmux //"|sed -n '1 p'|tr -cd [:digit:])" -eq "18" ]; th echo "Currently installed: $(tmux -V)" >> "${consolelog}" else touch "${consolelog}" - tmux pipe-pane -o -t ${servicename} "exec cat >> '${consolelog}'" + tmux pipe-pane -o -t "${servicename}" "exec cat >> '${consolelog}'" fi sleep 1 tmuxwc=$(tmux list-sessions 2>&1|awk '{print $1}'|grep -Ec "^${servicename}:") @@ -141,8 +141,8 @@ if [ "${tmuxwc}" -eq 0 ]; then echo "" echo "Command" echo "=================================" - echo "tmux new-session -d -s ${servicename} "${executable} ${parms}"" - echo "tmux new-session -d -s ${servicename} "${executable} ${parms}"" >> "${scriptlog}" + echo "tmux new-session -d -s "${servicename}" "${executable} ${parms}"" + echo "tmux new-session -d -s "${servicename}" "${executable} ${parms}"" >> "${scriptlog}" echo "" echo "Error" echo "=================================" @@ -188,4 +188,4 @@ if [ "${gamename}" == "Teamspeak 3" ]; then fn_start_teamspeak3 else fn_start_tmux -fi \ No newline at end of file +fi