e185c732dc
all : fix terminal ENV context and add doc nav
24 lines
453 B
Bash
Executable File
24 lines
453 B
Bash
Executable File
#!/bin/bash
|
|
# pluie/docker-images - a-Sansara (https://github.com/a-sansara)
|
|
|
|
. /scripts/dbcommon.sh
|
|
|
|
dbname=${1:-''}
|
|
shname=$(basename $0)
|
|
|
|
echoTitle
|
|
|
|
function usage(){
|
|
echo -e "\n ${Cusa}usage :${Coff}\n ${Ctext}$shname \t${Copt}DBNAME USER${Coff}"
|
|
}
|
|
|
|
if [ ! -z "$1" ]; then
|
|
mysqldump -uroot "$dbname" > "/dump/"$(date +"%y%m%d-%H%I")".$dbname.sql"
|
|
if [ $? -eq 0 ]; then
|
|
echo -e "\n done"
|
|
fi
|
|
echo
|
|
else
|
|
errEmptyDb
|
|
fi
|