File tree Expand file tree Collapse file tree 3 files changed +6
-5
lines changed
Expand file tree Collapse file tree 3 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ db_password=$4
2323type=$5
2424host=$6
2525encoding=${7-UTF8}
26-
26+ encoding= $( echo " $encoding " | tr ' [:lower:] ' ' [:upper:] ' )
2727# Importing variables
2828source $VESTA /conf/vars.conf
2929source $V_CONF /vesta.conf
@@ -89,7 +89,7 @@ increase_user_value "$user" '$U_DATABASES'
8989
9090# Adding db to db conf
9191v_str=" DB='$database ' USER='$db_user ' HOST='$host ' TYPE='$type '"
92- v_str=" $v_str U_DISK='0' SUSPEND='no' DATE='$V_DATE '"
92+ v_str=" $v_str LOCALE=' $encoding ' U_DISK='0' SUSPEND='no' DATE='$V_DATE '"
9393echo " $v_str " >> $V_USERS /$user /db.conf
9494
9595# Hiding password
Original file line number Diff line number Diff line change @@ -107,7 +107,7 @@ is_db_valid
107107conf=$V_USERS /$user /db.conf
108108
109109# Defining fileds to select
110- fields=' $DB $USER $HOST $TYPE $U_DISK $SUSPEND $DATE'
110+ fields=' $DB $USER $HOST $TYPE $CHARSET $ U_DISK $SUSPEND $DATE'
111111
112112# Listing database
113113case $format in
Original file line number Diff line number Diff line change @@ -40,13 +40,14 @@ is_user_valid
4040conf=$V_USERS /$user /db.conf
4141
4242# Defining fileds to select
43- fields=' $DB $USER $HOST $TYPE $U_DISK $SUSPEND $DATE'
43+ fields=' $DB $USER $HOST $TYPE $CHARSET $ U_DISK $SUSPEND $DATE'
4444
4545# Listing databases
4646case $format in
4747 json) json_list ;;
4848 plain) nohead=1; shell_list ;;
49- shell) shell_list | column -t ;;
49+ shell) fields=' $DB $USER $HOST $TYPE $U_DISK $DATE' ;
50+ shell_list | column -t ;;
5051 * ) check_args ' 1' ' 0' ' user [format]'
5152esac
5253
You can’t perform that action at this time.
0 commit comments