-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
2024-08-13/01: add "Abusing Makefiles for fun and profit" as draft
- Loading branch information
1 parent
f59a2ca
commit af1c3d6
Showing
1 changed file
with
32 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# Abusing Makefiles for fun and profit | ||
|
||
If you are following this blog for a while, it should be no surprise that most | ||
of the workflow in this blog is [automated using | ||
Go](/2024-07-29/01-quick-bits-why-you-should-automate-everything.md). I | ||
basically write Markdown files with some special rules inside the | ||
[repository](https://github.com/thiagokokada/blog), commit and push it. In | ||
seconds, the CI (currently [GitHub | ||
Actions](https://github.com/thiagokokada/blog/blob/4e3f25485c6682f3e066b219df2290934bc0d256/.github/workflows/go.yml)) | ||
will take the latest commit, generate some files (since I use the [repository | ||
itself](/2024-07-26/02-using-github-as-a-bad-blog-platform.md) as a backup | ||
blog) and publish to the [capivaras.dev | ||
website](https://kokada.capivaras.dev/). | ||
|
||
Now, considering how much about Nix I talk in this blog, it should be a | ||
surprise that the workflow above has **zero** Nix code inside it. I am not | ||
saying this blog will never have it, but I am only going to add if this is | ||
necessary, for example if I start using a tool to build this blog that I | ||
generally don't expect it to be installed by the machine I am currently using. | ||
Go is an exception of this rule since it is relatively straightfoward to | ||
install (just download the [binary](https://go.dev/doc/install)) and because | ||
its [stability guarantee](https://go.dev/doc/go1compat) means (hopefully) no | ||
breakage. But most other things I consider moving targets, and would not be | ||
comfortable to use unless I have Nix to ensure reproducibility. | ||
|
||
This is why the other tool that this blog (ab)uses during its workflow is | ||
[`Make`](https://en.wikipedia.org/wiki/Make_(software)), one of the oldest | ||
build automations software that exist. It is basically available in any *nix | ||
(do not confuse with [Nix](https://nixos.org/)) system, from most Linux distros | ||
to macOS, by default. So it is the tool I choose to automatise some tasks in | ||
this blog, even if I consider writing a `Makefile` (the DSL that `Make` uses) | ||
kind of a dark art. |