FOSS Unleashed

Lessons on mk (From 2025-05-11 stream)

Quick notes from what I learned about mk today on stream:

  • MKSHELL affects every place that would shell out (which is probably obvious, but not how I read the documentation)
  • =U= assignment seems to not work at all? But that doesn’t really matter since variables provided on the command line cannot be changed
  • If a subshell errors out, mk will warn, but continue
  • Subshells can be done with `{cmd ...} or `cmd ...` but not `cmd (as supported by rc and xs)

Finally, the following works (with MKSHELL = rcxs), but is so frustrating to use/write, there isn’t really any reason to do it:

1
2
3
4
<|{\
echo MKSHELL \= rcxs; \
echo dothis:V:\n\techo '\$target' \
}