From 23f04635cc26e1b0553088f28553f518488a9fc8 Mon Sep 17 00:00:00 2001 From: Joris Date: Wed, 1 May 2019 15:52:32 +0200 Subject: Setup personal page with Hakyll --- Makefile | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index e350236..446fb18 100644 --- a/Makefile +++ b/Makefile @@ -4,17 +4,21 @@ start: @nix-shell --command "tmuxinator local" stop: - @nix-shell --command "tmux kill-session -t personalPage" + @tmux kill-session -t personalPage clean: - @cabal new-clean > /dev/null + @stack exec personalPage clean > /dev/null 2>&1 || true + @stack clean > /dev/null -watch: - @nodemon --watch src/ application.conf ./data.yaml resume/ --ext hs,conf,yaml,cls --exec 'clear && make build-and-launch-server --silent' - -build-and-launch-server: - @(pkill personalPage || true) && (cabal new-run || true) +install: + @stack setup -.PHONY: build build: - @cabal new-build || true + @stack build + @stack exec personalPage build + +watch: + @nodemon --watch src -e hs --exec 'make watch-command --silent' + +watch-command: + @(killall personalPage || :) && sleep 1 && stack build && stack exec personalPage clean && stack exec personalPage watch -- cgit v1.2.3