In most cases, make clean is aliased by make clena (and other typos that I have made over the years). The current solution to check for the aliased string does not scale at all. A better solution is to set an array of variables that correspond to clean and check if any of those are present in MAKECMDGOALS
In most cases,
make clean
is aliased bymake clena
(and other typos that I have made over the years). The current solution to check for the aliased string does not scale at all. A better solution is to set an array of variables that correspond toclean
and check if any of those are present inMAKECMDGOALS