Double quotes

This commit is contained in:
Bob Mottram 2016-01-03 12:26:42 +00:00
parent 8ed901bac4
commit c98b3f0f8a
1 changed files with 3 additions and 3 deletions

View File

@ -115,7 +115,7 @@ function add_user {
} }
function pad_string { function pad_string {
echo -n -e "$1" | sed -e :a -e 's/^.\{1,15\}$/& /;ta' echo -n -e "$1" | sed -e :a -e 's/^.\{1,25\}$/& /;ta'
} }
function show_domains { function show_domains {
@ -200,7 +200,7 @@ function show_users {
for d in /home/*/ ; do for d in /home/*/ ; do
USRNAME=$(echo "$d" | awk -F '/' '{print $3}') USRNAME=$(echo "$d" | awk -F '/' '{print $3}')
if [[ $USRNAME != "git" ]]; then if [[ $USRNAME != "git" ]]; then
echo -n -e "$(pad_string '${USRNAME}')" echo -n -e "$(pad_string \"${USRNAME}\")"
# get the SIP extension # get the SIP extension
SIPEXT= SIPEXT=
while read ext; do while read ext; do
@ -214,7 +214,7 @@ function show_users {
fi fi
done < $SIP_CONFIG_FILE done < $SIP_CONFIG_FILE
if [ $SIPEXT ]; then if [ $SIPEXT ]; then
echo -n -e "$(pad_string 'SIP:${SIPEXT}')" echo -n -e "$(pad_string \"SIP:${SIPEXT}\")"
else else
echo -n -e "$(pad_string '')" echo -n -e "$(pad_string '')"
fi fi