1
0
Fork 0

Add deploy task

Dieser Commit ist enthalten in:
Starbeamrainbowlabs 2020-05-16 17:05:19 +01:00
Ursprung 4254560b4a
Commit 4076c79bef
Signiert von: sbrl
GPG-Schlüssel-ID: 1BE5172E637709C2
1 geänderte Dateien mit 11 neuen und 0 gelöschten Zeilen

11
build
Datei anzeigen

@ -19,6 +19,8 @@ config="./.eleventy.js"; # relative to src/
output_dir="${PWD}/public";
port_number="5726"
scp_path="starbeamrainbowlabs.com:/srv/pepperminty.wiki/www/";
###############################################################################
# Check out the lantern git submodule if needed
@ -41,6 +43,7 @@ if [[ "$#" -lt 1 ]]; then
echo -e " ${CACTION}server${RS} - Start a development busybox http server";
echo -e " ${CACTION}launch${RS} - Do both ${CACTION}server${RS} and ${CACTION}watch${RS}";
echo -e " ${CACTION}serve${RS} - Start a livereload server";
echo -e " ${CACTION}deploy${RS} - Build and deploy to the remote web server";
echo -e "";
exit 1;
@ -120,6 +123,14 @@ task_serve() {
task_end "$?";
}
task_deploy() {
tasks_run build;
task_begin "Deploying pepperminty.wiki";
scp -r ${output_dir}/* "${scp_path}";
task_end "$?";
}
###############################################################################
tasks_run "$@";