Re:Learn Makefiles with the Tastiest Examples
by silverwind on Monday May 15, 2023 @07:59PM
(#35956181)
I too use Make to install `node_modules` and `.venv`.
It is very convenient never having to ask oneself "Is my node_modules up to date?" after pulling or switching branches. I'll just let Make figure that out.
> and docker doesn’t give definable artifacts so you can’t make other things depend on them either
Similar to how old projects have "make configure" to do some initial setup before "make" actually builds the project, I've done stuff on occasion where something like "make check" would pull information out of a system and create timestamped files in a scratch/ directory. Then the normal "make" would compare those files to the codebase to see if the system needed to be updated.
It is different from the first use I just mentioned, since you need two commands and it's not entirely automatic, but it's still simpler than checking each of the dependencies yourself.