Skip to content

Instantly share code, notes, and snippets.

@Lamby777
Forked from ttencate/Makefile
Created June 7, 2023 01:45
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 Lamby777/5ccbbfed64057d7c2d02ab3e678aa106 to your computer and use it in GitHub Desktop.
Save Lamby777/5ccbbfed64057d7c2d02ab3e678aa106 to your computer and use it in GitHub Desktop.
The best Makefile ever
ifeq ($(MAKECMDGOALS),me a sandwich)
.PHONY: me a sandwich
me a:
@true
sandwich:
@if [[ $$(id -u) == "0" ]]; then \
echo "Okay."; \
else \
echo "What? Make it yourself."; \
false; \
fi
endif
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment