The third link has a link to
http://www.catb.org/%7Eesr/jargon/html/Y/yak-shaving.html> [MIT AI Lab, after 2000: orig. probably from a Ren & Stimpy episode.] Any seemingly pointless activity which is actually necessary to solve a problem which solves a problem which, several levels of recursion later, solves the real problem you're working on.
So yeah, both in your first link (mostly) and here: prerequisite - something you have to do, not a side thing like the clip of Hal. That GIF has apparently been misused this whole time, muddying the issue.
(The first link ends with the equivalent of "you can avoid yak shaving by introducing technical debt")