ads1_2021/code/golang/Makefile

22 lines
766 B
Makefile
Raw Normal View History

2021-11-06 10:55:44 +01:00
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# LOCAL ARGUMENTS
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
PATH_TO_ARTEFACT:=../../dist/ads
PATH_TO_CONFIG:=../config.yml
2021-11-06 11:02:53 +01:00
COLOUR:=true# <- auf false stellen, falls es Probleme gibt
2021-11-06 10:55:44 +01:00
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# TARGETS
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
setup:
go mod download
build:
go build -o ${PATH_TO_ARTEFACT} main.go
run: # non-interactive mode mit config-datei
2021-11-06 11:02:53 +01:00
${PATH_TO_ARTEFACT} run --debug --colour ${COLOUR} --config "${PATH_TO_CONFIG}"
2021-11-06 10:55:44 +01:00
run-it: # interactive mode
2021-11-06 11:02:53 +01:00
${PATH_TO_ARTEFACT} run --it --debug --colour ${COLOUR}
2021-11-06 10:55:44 +01:00
# Do everything:
all: setup build run
all-it: setup build run-it