moth/packages/mcp/bin/new-contest

30 lines
632 B
Bash
Executable File

#! /bin/sh
if [ "$1" != "-f" ]; then
echo "Usage: $0 -f"
echo
echo "Wipes out the current contest. This operation is not"
echo "reversable, which is why you have to specify -f to signify"
echo "that you know what you're getting into."
exit
fi
sv d tokend
sv d pointsd
sv d puzzled
sv d tanksd
rm -f $CTF_BASE/state/tokens.db
rm -f $CTF_BASE/state/points.log
rm -f $CTF_BASE/www/scoreboard.html
rm -f $CTF_BASE/state/puzzles.db
rm -rf $CTF_BASE/state/points.new
rm -rf $CTF_BASE/state/points.tmp
rm -rf $CTF_BASE/state/tanks
rm -rf $CTF_BASE/state/teams
sv u tokend
sv u pointsd
sv u puzzled
sv u tanksd