Quick back-of-the-envelope evaluation of make
and Taskfile:
Feature | Makefile | Taskfile |
---|---|---|
Built-in | often | no |
Avoids YAML | yes | no |
Insignifcant tab characters | no | yes |
Hierarchical | no | yes |
Reads .env files |
actually | yes |
I think the main benefit of make
is that it's almost always there; no other software to install. Taskfile requires the executable, which (to its credit) is a single binary, but is an extra step. (Also: it's probably not on the approved software list (but then again, neither is my preferred text editor).)
Makefile
s avoid YAML, which is a benefit. But Makefile
s require TAB characters which can be easily lost and cause confusing errors.
Taskfiles are hierarchical, which is neat: taskfile.yaml
s are automatically discovered in parent (and grandparent, etc.) directories and brought in, allowing you to customize as you go deeper.
The main benefit of a Taskfile is that it'll read a .env
file automatically. This means that the same environments we have for Terraform and and for Docker Compositions work with Taskfile too, which is superb.
To be fair, make
can also read .env
files, but must be explicitly included:
include .env