blob: 62f39a9b01c86d01a0c170b1a943ef4fd70f98fb (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
# created by Urchlay
#!/bin/sh
if [ -z "$HOME" ]; then
echo "$0: \$HOME not set in the environment, aborting" 1>&2
exit 1
fi
DBDIR="$HOME/.local/var/mathics/"
# In case of multiple installs, SCRIPT prefers /usr/lib64 to /usr/lib,
# and higher-numbered python versions to lower-numbered. But this is
# just paranoia, there shouldn't be multiple mathics installations.
SCRIPT=$( /bin/ls -d /usr/lib*/python2.*/site-packages/mathics/manage.py | tac | head -1 )
echo "Initializing mathics SQLite databases in $DBDIR"
mkdir -p $DBDIR
exec python $SCRIPT syncdb --noinput
|