From ff241e6757f4811dc58033946ebff43ff25a2231 Mon Sep 17 00:00:00 2001 From: wingaxe Date: Mon, 2 Dec 2024 21:42:15 -0500 Subject: [PATCH] Adding help option in makefile --- Makefile | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 6f5060a..ac2fbbf 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,14 @@ -map.txt: map.ge - grep -v '# unimportant' $< | graph-easy --boxart > $@ +.PHONY: help -full_map.txt: map.ge +help: ## Print the help message + @awk 'BEGIN {FS = ":.*?## "} /^[0-9a-zA-Z._-]+:.*?## / {printf "\033[36m%s\033[0m : %s\n", $$1, $$2}' $(MAKEFILE_LIST) | \ + sort | \ + column -s ':' -t + +map.txt: map.ge ## Making map.txt + grep -v '# unimportant' $< | graph-easy --boxart > $@ + cat $@ + +full_map.txt: map.ge ## Generating full_map.txt with graph-easy graph-easy --boxart < $< > $@ + cat $@