Skip to content

Instantly share code, notes, and snippets.

@kaibosh
Last active February 7, 2017 10:19
Show Gist options
  • Save kaibosh/74f53404c4bf661f887458a754fd261b to your computer and use it in GitHub Desktop.
Save kaibosh/74f53404c4bf661f887458a754fd261b to your computer and use it in GitHub Desktop.
helper.sh with showsleep
#!/bin/sh
if [ -e "nZEDbBase.php" ]
then
export NZEDB_ROOT="$(pwd)"
else
export NZEDB_ROOT="$(php ../../../../../nZEDbBase.php)"
fi
export NZEDB_PATH="${NZEDB_ROOT}/misc/update"
export THREADED_PATH="${NZEDB_ROOT}/misc/update/nix/multiprocessing"
export TEST_PATH="${NZEDB_ROOT}/misc/testing"
command -v php5 >/dev/null 2>&1 && export PHP=`command -v php5` || { export PHP=`command -v php`; }
export NZEDB_SLEEP_TIME="60"
while :
do
cd ${NZEDB_PATH}
$PHP $THREADED_PATH/releases.php
cd ${TEST_PATH}
$PHP ${TEST_PATH}/Release/removeCrapReleases.php true 1
$PHP ${NZEDB_PATH}/nix/tmux/bin/showsleep.php $NZEDB_SLEEP_TIME
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment