In a script, if you open a file descriptor like this: eval exec 3>&1 and redirect output from certain commands to it like this: echo blub >&3 then you can redirect only that certain output to a different file if needed when calling the script. By default all goes to stdout, but when called like this: ./script 3>>file1 >>file2 then you can check the separated output in file1 and the rest of stdout in file2.
Bash Tip
Entry created on 2022-11-30
author:steeph (374)
cat:Bash (31)
cat:File Descriptors (1)
cat:Output Redirection (1)
cat:Software (53)
lang:en (253)
Entry created on 2022-11-29 author:steeph (374) cat:Conversation (2) cat:Jokes (4) cat:Silly (29) lang:en (253)
Where were you born?
Hmm, I'm not sure. That was such a long time ago. I can't remember. Where were you born?
In a hospital.
Huh, just like me.
Entry created on 2022-11-27 author:steeph (374) cat:Bash (31) cat:Linux (36) lang:en (253)
When I started to really use Linux I followed the common suggestion to read all the relevant man pages. I skipped a lot. But I still sometimes feel like it is useful that I've read about a thing or another before. I attempted to read the bash manual back then, but it was just too much at once.
Many years later I started to use more of my shell's potential, which was still bash. Now I'm used to write scripts and have written a relatively large application in bash, but had never read the entire bash manual.
Until this year. I've read the entire bash man page. And yes, I did learn useful new things.
Entry created on 2022-11-27 author:steeph (374) cat:Linux (36) cat:Talks (4) cat:Video (1) lang:en (253)
I like how "Linux on the desktop" is still the same running joke nowadays even though the vision has lost it's relevance as a goal.
Linux on mobile is nowaday's "Linux on the desktop". And don't make the mistake to think that Android is Linux and so Linux has won.
Here's a talk from this year about Linux Mobile: "Is there hope for Linux on smartphones?" by Guido Günther
Entry created on 2022-11-25 author:steeph (374) cat:2022 (4) cat:Thoughts (71) cat:Toothbrush (1) lang:en (253)
2022 was the year in which I've learned to accept that a toothbrush costs more than a few cents and that I have to start using a new one more often than once or twice a year. It's not actually that much money that goes into toothbrushes compared to other things adult me has to pay for.