[#172] Makefile: Add filter to help target
Signed-off-by: Angira Kekteeva <kira@nspcc.ru>
This commit is contained in:
parent
f7ead4b014
commit
5dc86e2aac
1 changed files with 3 additions and 1 deletions
4
help.mk
4
help.mk
|
@ -1,5 +1,7 @@
|
||||||
.PHONY: help
|
.PHONY: help
|
||||||
|
|
||||||
|
HELP_MAKEFILE_LIST=$(filter-out %/artifacts.mk, $(MAKEFILE_LIST))
|
||||||
|
|
||||||
# Show this help prompt
|
# Show this help prompt
|
||||||
help:
|
help:
|
||||||
@echo ' Usage:'
|
@echo ' Usage:'
|
||||||
|
@ -8,4 +10,4 @@ help:
|
||||||
@echo ''
|
@echo ''
|
||||||
@echo ' Targets:'
|
@echo ' Targets:'
|
||||||
@echo ''
|
@echo ''
|
||||||
@awk '/^#/{ comment = substr($$0,3) } comment && /^[a-zA-Z][a-zA-Z0-9._/-]+ ?:/{ print " ", $$1, comment }' $(MAKEFILE_LIST) | column -t -s ':' | grep -v 'IGNORE' | sort -u
|
@awk '/^#/{ comment = substr($$0,3) } comment && /^[a-zA-Z][a-zA-Z0-9._/-]+ ?:/{ print " ", $$1, comment }' $(HELP_MAKEFILE_LIST) | column -t -s ':' | grep -v 'IGNORE' | sort -u
|
||||||
|
|
Loading…
Reference in a new issue