Skip to content

Instantly share code, notes, and snippets.

@mkhl
Created August 8, 2022 18:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mkhl/2ec0aba1bbffeb2eb4ace707e751851c to your computer and use it in GitHub Desktop.
Save mkhl/2ec0aba1bbffeb2eb4ace707e751851c to your computer and use it in GitHub Desktop.
my `make help` variant

like https://github.com/kris-nova/Makefile but:

  • supports targets with digits in their names
  • supports targets in included makefiles
  • doesn't sort the targets (i can order them in the makefile)
  • doesn't force color into my terminal
  • doesn't use grep, only awk
.PHONY: help
help: ## Show this help
@awk -F ':.* ## ' '/^\w.*##/{printf "%-15s %s\n", $$1, $$2}' $(MAKEFILE_LIST)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment