Please see this repository for a minimal example of what I’m talking about.
masterhas the problem, while branch
2-touch-fileshas a workaround that doesn’t scale well.
I wonder if there is a way to make GitLab CI stages work with Make, such that I can re-use the Makefile targets that I use locally in GitLab CI without invoking the commands manually via
.gitlab-ci.yml. I prefer not to repeat these commands and logic.
I believe the reason I see a recompile of the
helloworld binary because the timestamp of the
helloworld.cpp file is newer (due to checkout) than the
helloworld binary. I therefore wonder if there is a way to prevent this from happening, other than touching all artifacts from previous stages in every stage.