diff --git a/bin/vmail-aliases-get.sh b/bin/vmail-aliases-get.sh index 1b59811..f8387ee 100755 --- a/bin/vmail-aliases-get.sh +++ b/bin/vmail-aliases-get.sh @@ -20,7 +20,7 @@ help() echo " -a Return info for specific alias." echo " -e Return all aliases for specified email address." echo " -d Return all aliases for specified domain." - echo " -c Output in cvs format." + echo " -c Output in csv format." echo " -t Use tabs instead of tables for output, do not display column headers." echo "" echo " Search term is optional. If nothing specified all aliases for all email acccounts for all domains will be returned." @@ -61,4 +61,4 @@ fi dbquery="$dbquery ORDER BY domain, mbox, alias;"; # execute mysql query -eval $dbcmd $dbcmdopts "\"$dbquery\"" $cvs +eval $dbcmd $dbcmdopts "\"$dbquery\"" $csv diff --git a/bin/vmail-autoresponders-get.sh b/bin/vmail-autoresponders-get.sh index 81e3fd2..8b22e1c 100755 --- a/bin/vmail-autoresponders-get.sh +++ b/bin/vmail-autoresponders-get.sh @@ -19,7 +19,7 @@ help() echo " -h Print this help." echo " -e Email address to get autresonder for." echo " -d Domain to get all autoresponders for." - echo " -c Output in cvs format." + echo " -c Output in csv format." echo " -t Use tabs instead of tables for output, do not display column headers." echo "" echo " Search term is optional. If nothing specified all forwards for all email acccounts for all domains will be returned." @@ -53,4 +53,4 @@ fi # sort results dbquery="$dbquery ORDER BY domain, mbox" # execute mysql query -eval $dbcmd $dbcmdopts "\"$dbquery\"" $cvs +eval $dbcmd $dbcmdopts "\"$dbquery\"" $csv diff --git a/bin/vmail-defaults-get.sh b/bin/vmail-defaults-get.sh index 18d1659..d84e0b0 100755 --- a/bin/vmail-defaults-get.sh +++ b/bin/vmail-defaults-get.sh @@ -17,7 +17,7 @@ help() echo "usage: $thisfilename [-c] [-h]" echo "" echo " -h Print this help." - echo " -c Output in cvs format." + echo " -c Output in csv format." echo echo " Returns defaults configured in the vm_domains table schema." exit @@ -30,25 +30,25 @@ dbcmdopts="-s -N -e" # get "status" default dbquery="SELECT COLUMN_DEFAULT FROM information_schema.columns WHERE TABLE_SCHEMA = 'vmail' AND TABLE_NAME = 'vm_domains' AND COLUMN_NAME = 'status'" -status=`eval $dbcmd $dbcmdopts "\"$dbquery\"" $cvs` +status=`eval $dbcmd $dbcmdopts "\"$dbquery\"" $csv` # get "mbox_limit" default dbquery="SELECT COLUMN_DEFAULT FROM information_schema.columns WHERE TABLE_SCHEMA = 'vmail' AND TABLE_NAME = 'vm_domains' AND COLUMN_NAME = 'mbox_limit'" -mbox_limit=`eval $dbcmd $dbcmdopts "\"$dbquery\"" $cvs` +mbox_limit=`eval $dbcmd $dbcmdopts "\"$dbquery\"" $csv` # get "mbox_quota_default" default dbquery="SELECT COLUMN_DEFAULT FROM information_schema.columns WHERE TABLE_SCHEMA = 'vmail' AND TABLE_NAME = 'vm_domains' AND COLUMN_NAME = 'mbox_quota_default'" -mbox_quota_default=`eval $dbcmd $dbcmdopts "\"$dbquery\"" $cvs` +mbox_quota_default=`eval $dbcmd $dbcmdopts "\"$dbquery\"" $csv` # get "mbox_ratelimit_default" default dbquery="SELECT COLUMN_DEFAULT FROM information_schema.columns WHERE TABLE_SCHEMA = 'vmail' AND TABLE_NAME = 'vm_domains' AND COLUMN_NAME = 'mbox_ratelimit_default'" -mbox_ratelimit_default=`eval $dbcmd $dbcmdopts "\"$dbquery\"" $cvs` +mbox_ratelimit_default=`eval $dbcmd $dbcmdopts "\"$dbquery\"" $csv` # create newline var NL=$'\n' output="status mbox_limit mbox_quota_default mbox_ratelimit_default${NL}$status $mbox_limit $mbox_quota_default $mbox_ratelimit_default" -if [[ $cvs ]]; then +if [[ $csv ]]; then echo "$output" | tr " " "," else echo "$output" | column -t diff --git a/bin/vmail-dkim-get.sh b/bin/vmail-dkim-get.sh index 5e38d1f..8b32f2f 100755 --- a/bin/vmail-dkim-get.sh +++ b/bin/vmail-dkim-get.sh @@ -18,7 +18,7 @@ help() echo "" echo " -h Print this help." echo " -d Domain name to get DKIM info for." - echo " -c CVS - Output in cvs format, instead of tabbed table." + echo " -c CSV - Output in csv format, instead of tabbed table." echo "" exit } @@ -49,7 +49,7 @@ if [[ ${#domains[@]} > 0 ]]; then dkim=`cat /etc/ssl/dkim/$domain.dkim` output="$output${NL}$domain $selector $dkim" done - if [[ $cvs ]]; then + if [[ $csv ]]; then echo "$output" | tr " " "," else echo "$output" | column -t diff --git a/bin/vmail-domains-get.sh b/bin/vmail-domains-get.sh index 3cec059..990c656 100755 --- a/bin/vmail-domains-get.sh +++ b/bin/vmail-domains-get.sh @@ -19,7 +19,7 @@ help() echo " -h Print this help." echo " -d Domain to be queried." echo " -g Glob - Wildcard search instead of specific domain search." - echo " -c Output in cvs format." + echo " -c Output in csv format." echo " -t Use tabs instead of tables for output, do not display column headers." echo "" echo " Domain/Glob is optional. If nothing specified all domains will be queried." @@ -49,4 +49,4 @@ fi dbquery="$dbquery ORDER BY domain" # execute mysql query -eval $dbcmd $dbcmdopts "\"$dbquery;\"" $cvs +eval $dbcmd $dbcmdopts "\"$dbquery;\"" $csv diff --git a/bin/vmail-forwards-get.sh b/bin/vmail-forwards-get.sh index 268f1b3..a8aec7d 100755 --- a/bin/vmail-forwards-get.sh +++ b/bin/vmail-forwards-get.sh @@ -20,7 +20,7 @@ help() echo " -e Email address to get forwarding for." echo " -f Return info for specific forward." echo " -d Get all forwards for specified domain." - echo " -c Output in cvs format." + echo " -c Output in csv format." echo " -t Use tabs instead of tables for output, do not display column headers." echo "" echo " Search term is optional. If nothing specified all forwards for all email acccounts for all domains will be returned." @@ -54,4 +54,4 @@ fi dbquery="$dbquery ORDER BY domain, mbox, forward_to;"; # execute mysql query -eval $dbcmd $dbcmdopts "\"$dbquery\"" $cvs +eval $dbcmd $dbcmdopts "\"$dbquery\"" $csv diff --git a/bin/vmail-mboxes-get.sh b/bin/vmail-mboxes-get.sh index 91a51d3..33b1de2 100755 --- a/bin/vmail-mboxes-get.sh +++ b/bin/vmail-mboxes-get.sh @@ -20,7 +20,7 @@ help() echo " -m Return all email accounts, accross all domains, with for the local part." echo " -d Return all email accounts from specified domain." echo " -e Specific email address to search for." - echo " -c Output in cvs format." + echo " -c Output in csv format." echo " -t Use tabs instead of tables for output, do not display column headers." echo " -v Include encrypt password in output." echo "" @@ -66,4 +66,4 @@ fi dbquery="$dbquery ORDER BY domain, mbox;"; # execute mysql query -eval $dbcmd $dbcmdopts "\"$dbquery\"" $cvs +eval $dbcmd $dbcmdopts "\"$dbquery\"" $csv diff --git a/bin/vmail.sh b/bin/vmail.sh index e7b036e..32d18da 100755 --- a/bin/vmail.sh +++ b/bin/vmail.sh @@ -111,8 +111,8 @@ function vmail:getoptions () { b ) # body - Body for Autoresponder emails body="${OPTARG}" ;; - c ) # cvs - output in cvs format - cvs="| sed 's/\t/,/g'" + c ) # csv - output in csv format + csv="| sed 's/\t/,/g'" ;; d ) # domain name (virtualhost) to act on domain=${OPTARG,,}