These files are created to abstract common tasks and are designed to be used primarily for local development usage only.
The primary prerequisite is to have Docker Desktop (or just Docker) installed.
As much as possible is done via Docker to prevent individuals from having to install multiple applications or libraries as well as worrying about what versions are needed.
In the event other applications are needed (i.e. Git) you will receive an error if they are not installed.
To use these files within your repository, you can copy and paste the code from init.mk to the top of your repository Makefile.
Alternatively, you can write a custom adaptation to replicate the same functionality.
Files can then be included into your repository folder specific Makefiles, as needed.
By putting the basic usage example above at the top of your Makefile you can then either run make init or make.
The example uses init but can be whatever you'd prefer, for example install could be used instead.
In the basic usage above, the MAKE_DIR variable is set to use .make as a directory within the root of the repository.
It is also recommended ignoring the directory from your repository by adding .make in the .gitignore file in the root of the repository.
These files are versioned and follow semantic versioning which is achieved with Git tags,
each patch version is immutable and will never change while the minor and major tags are mutable and will move based on the relevant patch version.
It is recommended to lock your MAKE_VERSION to the current major version.
The above will include and download any files defined by MAKE_FILES which is a space delimited list.
To include other files, it can be updated like so:
init: MAKE_FILES = terraform