5 ms·
Shorter, more fail-proof help target: help: @awk -F ':|##' \ '/^[^\t].+?:.*?##/ {\ printf "\033[36m%-30s\033[0m %s\n", $$1
by m6w6 11y ago
Shorter, more fail-proof help target:
help:
@awk -F ':|##' \
'/^[^\t].+?:.*?##/ {\
printf "\033[36m%-30s\033[0m %s\n", $$1, $$NF \
}' $(MAKEFILE_LIST)
... but I agree, breaking expectations is somewhat bad.
Also, many shells have completion for Makefiles nowadays, though, that won't get you an additional help text.