mirror of
https://codeberg.org/scip/note.git
synced 2025-12-17 20:51:02 +01:00
are two different version of the script in the same time with
the same features, one for mysql and the other one for the binary
database.
ADDED: Dump to textfile capability. Later on I want to dump it into a
palm readable format, any help is welcome!
ADDED: interactive mode.
CHANGED: Better modularity, better code.
CHANGED: note can now run without the need of a config file. If does not
exist, it will try to work with default values.
ADDED: sub num_bereich(), which allows one to specify more then one
number for deletion or displaying (i.e.: "-d 1,4,7" or "-d 4-9")
34 lines
711 B
Bash
Executable File
34 lines
711 B
Bash
Executable File
#!/bin/sh
|
|
# installs note
|
|
# This is the installer for the mysql version only!
|
|
|
|
echo "Welcome to note `cat VERSION` installation."
|
|
echo "the install script will ask you a view questions,"
|
|
echo "make sure to answer them correctly!"
|
|
echo
|
|
|
|
/bin/echo -n "creating the note database..."
|
|
NAME="_note"
|
|
DBNAME="$USER$NAME"
|
|
echo "DBNAME=$DBNAME"
|
|
mysqladmin create $DBNAME
|
|
echo "done."
|
|
/bin/echo -n "creating the table structure using defaults..."
|
|
mysql $DBNAME < sql
|
|
|
|
echo "Shall I try to install the required MySQL driver from CPAN?"
|
|
read YESNO
|
|
|
|
case $YESNO in
|
|
"y" | "Y")
|
|
if [ $UID != 0 ] ; then
|
|
echo "You should be root for that!"
|
|
exit
|
|
fi
|
|
perl -MCPAN -e shell cpan> install mysql
|
|
;;
|
|
esac
|
|
echo "done."
|
|
|
|
|