REDO-WHICHDO(1)

πŸ“¦
version 4.0.7 Β· 2 versions
, in arch rolling, nixos 26.05, nixpkgs unstable

🌸 NAME 🌸

Okay so this is the redo-whichdo(1) page from the General Commands Manual, and redo-whichdo literally prints the search paths for dofiles to build a redo target. That's the whole assignment, bestie πŸ’…


✨ SYNOPSIS ✨

redo-whichdo target

πŸ¦‹ DESCRIPTION πŸ¦‹

First things first, context queen: redo(1) is a tool for building files and for rebuilding them if any of their dependencies have changed. Periodt. And redo-whichdo? She prints all the dofiles that redo(1) will look for to build the target. The whole lineup. No skipping. πŸ’–

If the exit code of redo-whichdo indicates success, then the last filename is the filename of the dofile that redo(1) will actually use to build the target. That's the one that gets the crown πŸ‘‘

Here's the actual vibe check: redo-whichdo prints the filename for a dofile that redo(1) could use to build the target. If that dofile exists, redo-whichdo exits with a status code indicating success. Slay. If the dofile does not exist, redo-whichdo either repeats the previous action with a fallback filename or exits with a status code indicating error if redo-whichdo can not find a dofile to build the target. Not me getting emotional about fallback filenames 😭

And the separator tea β˜•: if standard output is a terminal, redo-whichdo separates filenames by newline characters. Otherwise, redo-whichdo separates filenames by null characters. Shell scripts that act on the output of redo-whichdo can pipe it to xargs(1) invoked with the -0 option to handle the filenames. iykyk 🫢


πŸŽ€ EXAMPLES πŸŽ€

Imagine a root directory containing only the three dofiles a.do, default.b.do, default.c.do, and a folder d. For the targets, a, a.b, and a.b.c, d/a.b.c, the output of redo-whichdo(1) would be these:

a

/a.do

a.b

/a.b.do
/default.b.do

a.b.c

/a.b.c.do
/default.b.c.do
/default.c.do

d/a.b.c

/d/a.b.c.do
/d/default.b.c.do
/d/default.c.do
/d/default.do
/default.b.c.do
/default.c.do

πŸ”₯ NOTES πŸ”₯

A dofile used to build a target is a dependency of that target: if redo(1) determines that the dofile used to build a target has changed, the target will be rebuilt. Literally cause and effect, no cap πŸ’€

Also: all non-existent dofiles searched for while building a target are non-existence dependencies of that target. If redo(1) finds that a previously searched for non-existent dofile exists, the target will be rebuilt. The way that works is so iconic ngl 🌈


πŸ‘‘ HISTORY πŸ‘‘

redo-whichdo was designed by Avery Pennarun and Γ†lla Chiana Moskopp as part of Avery Pennarun's redo implementation and independently implemented by Γ†lla Chiana Moskopp. We stan the collaboration πŸ’œ


🌸 AUTHOR 🌸

redo-whichdo and this man page were written by Γ†lla Chiana Moskopp. Queen behavior, honestly πŸŽ€


Copyright Β© 2018-2019 Γ†lla Chiana Moskopp. License AGPLv3+: GNU Affero GPL version 3 or later <http://www.gnu.org/licenses/agpl-3.0.html>. This is free software: you are free to change and redistribute it.

There is NO WARRANTY, to the extent permitted by law. πŸ’€

πŸ¦‹ SEE ALSO πŸ¦‹


And that's the whole page, bestie β€” this is REDO-WHICHDO(1) from the General Commands Manual, and the footer is literally just REDO-WHICHDO(1) with no date stamped, just vibes. Mwah πŸ’‹βœ¨

πŸ“¦ where this page comes from