/usr/bin/gnomint-upgrade-db is in gnomint 1.2.1-8.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 | #!/bin/sh
if [ $# -ne 1 ]
then
echo
echo "gnoMint database converter"
echo "by David Marin <davefx@gmail.com>"
echo " "
echo " Sintax: $0 ( -h | --help | gnoMint-db.filename ) "
echo " "
echo " `basename $0` converts an old (pre 0.1.4 version) gnoMint "
echo " database (based in sqlite2) into a new database compatible with "
echo " gnoMint 0.1.4 and newer, based in sqlite3"
echo
fi
if [ ! `which sqlite` ]
then
echo "Sorry, but sqlite program (version 2) is required for make the "
echo "conversion. Please install it."
exit
fi
if [ ! `which sqlite3` ]
then
echo "Sorry, but sqlite3 program is required for make the conversion. Please"
echo "install it."
exit
fi
if [ ! -e $1 ]
then
echo "Sorry, the given file '$1' doesn't exist."
exit
fi
if [ \( ! -r $1 \) -o \( ! -w $1 \) ]
then
echo "Sorry. You don't have enough permissions for reading and/or writing"
echo "the given file."
exit
fi
TMPFILE=`mktemp`
echo .dump | sqlite $1 > $TMPFILE || (echo "There was a problem while extracting data from file."; echo "Conversion process cancelled"; exit)
mv $1 $1.bak
cat $TMPFILE | sqlite3 $1 && rm $TMPFILE
echo "File converted successfully."
|