Files

14 lines
315 B
Bash
Raw Permalink Normal View History

#!/usr/bin/env bash
2020-12-11 13:41:42 +08:00
set -euo pipefail
2020-12-11 13:41:42 +08:00
DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
2020-12-11 13:41:42 +08:00
if [ ! -e "$DIR/data/config.php" ]; then
2020-12-11 13:41:42 +08:00
cp "$DIR/data/config.php.example" "$DIR/data/config.php"
fi
"$DIR/hooks/install.sh"
2020-12-11 13:41:42 +08:00
composer --working-dir="$DIR" install
php -S 0.0.0.0:8000 -t "$DIR/web" "$DIR/web/index.php"