Issue 67 in gnizr: Warn db overwrite when running the install script

2 views
Skip to first unread message

codesite...@google.com

unread,
Jun 4, 2008, 12:11:58 PM6/4/08
to gnizr-dev...@googlegroups.com
Issue 67: Warn db overwrite when running the install script
http://code.google.com/p/gnizr/issues/detail?id=67

Comment #2 by harry.chen:
(No comment was entered for this change.)


Issue attribute updates:
Status: Fixed

--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings

codesite...@google.com

unread,
Jun 4, 2008, 12:20:12 PM6/4/08
to gnizr-dev...@googlegroups.com
Issue 67: Warn db overwrite when running the install script
http://code.google.com/p/gnizr/issues/detail?id=67

Comment #3 by harry.chen:
Based on rick's suggestion (may 29, 08),

http://code.google.com/p/gnizr/wiki/SetupGnizrDatabase

I modified his script and added the following:

rows=`mysql -u $USER -p${PASS} -e "show tables" $DB |wc -l`
if [ $rows -gt 0 ]
then echo "Looks like the gnizr has already been installed."
echo "Enter YES to continue (ALL EXISTING DATA WILL BE LOST!): "
read input
if [ "$input" != "YES" ]
then echo "Quit! No changes are made."
exit 1
fi
fi

Reply all
Reply to author
Forward
0 new messages