2020-12-23 01:48:34 -06:00
|
|
|
ifeq ($(PREFIX),)
|
|
|
|
PREFIX := /usr/local
|
|
|
|
endif
|
|
|
|
|
|
|
|
all: release
|
|
|
|
|
|
|
|
.PHONY: clean
|
|
|
|
clean:
|
|
|
|
rm -f blogtool
|
|
|
|
|
|
|
|
.PHONY: run
|
|
|
|
run:
|
|
|
|
crystal run src/blogtool.cr
|
|
|
|
|
2020-12-23 10:18:47 -06:00
|
|
|
release: dependencies
|
2020-12-23 01:48:34 -06:00
|
|
|
crystal build --release --no-debug src/blogtool.cr
|
|
|
|
|
2020-12-23 10:18:47 -06:00
|
|
|
dependencies:
|
|
|
|
shards install
|
|
|
|
|
|
|
|
debug:
|
|
|
|
crystal build src/blogtool.cr
|
|
|
|
|
|
|
|
test: debug
|
|
|
|
cd testsite && ../blogtool
|
2020-12-23 01:48:34 -06:00
|
|
|
|
|
|
|
install:
|
2020-12-23 10:18:47 -06:00
|
|
|
install blogtool $(PREFIX)/bin/
|
|
|
|
mkdir -p /etc/blogtool
|
|
|
|
install testsite/base.html /etc/blogtool/
|