This really enterprises my bash.
Comment on How do you shell expand your variables and why?
ilega_dh@feddit.nl 1 year ago
find “$(echo $HOME > variable_holder.txt && cat variable_holder.txt)/$(cat alphabet.txt | grep “d”) $(cat alphabet.txt | grep “o”)$(cat alphabet.txt | grep “c”)$(cat alphabet.txt | grep “s”)”
This is the easiest method
ale@lemmy.world 1 year ago
thingsiplay@kbin.social 1 year ago
gendulf@kbin.social 1 year ago
To be safe, should probably output grep to a file, then cat that.
ilega_dh@feddit.nl 1 year ago
Agreed. Everything in Linux is a file so let’s keep it that way.
eager_eagle@lemmy.world 1 year ago
when you’re paid by character written
monsterpiece42@reddthat.com 1 year ago
What should I search to better understand what is written here? Don’t mind learning myself, just looking for the correct keywords. Thanks!
oneiros@lemmy.blahaj.zone 1 year ago
This comment is a joke and you wouldn’t want to do it like that in reality, but here are some related keywords you could look up: “Unix cat”, “Unix pipeline”, “grep”, “output redirection”, “command substitution”.
priapus@sh.itjust.works 1 year ago
ExplainShell should help
marcos@lemmy.world 1 year ago
Read the Bash manual. That one patter on the GP is called “Command Substitution”, you can search for it.
igorlogius@lemmy.world 1 year ago
no
eval
?