Skip to content

Latest commit

 

History

History
19 lines (13 loc) · 473 Bytes

make.md

File metadata and controls

19 lines (13 loc) · 473 Bytes

Make

Pass all args to target

StackOverflow

action:
        @echo action $(filter-out $@,$(MAKECMDGOALS))

%:
    @:

filter-out is a function that removes some elements from a list. So $(filter-out bar, foo bar baz) returns foo baz

$@ is an automatic variable for the name of the target of the rule, in this case "action"

%: is a rule which matches any task name

@: is a no-op recipe