manned/util/cron.sh

18 lines
375 B
Bash
Executable file

#!/bin/sh
PSQL="psql -U manned -Awtq"
./alpine.sh current
./arch.sh current
./debian.sh current
./centos.sh current
./fedora.sh current
./ubuntu.sh current
# Only update indices once a week (on mondays). This process is slow and the data doesn't often change anyway.
if [ `date +%u` == 1 ]
then
echo "============ Updating SQL indices"
$PSQL -f update_indices.sql
fi