3 ms·
Instead of: $ fortune > my_fortune.txt $ say -f my_fortune.txt One could use the underrated (bashism) process substitution: $ say -f <(fortune)
by lloeki 10y ago
Instead of:
$ fortune > my_fortune.txt
$ say -f my_fortune.txt
One could use the underrated (bashism) process substitution:
$ say -f <(fortune)
Which works wonders for e.g diff'ing live:
$ diff <(ssh elvis ls -1 foo) <(ls -1 bar)
- masklinn 10y agoWhy would you even bother with that when `say` can take a string or read from stdin? Just use $ say $(fortune) or $ fortune | say -f- For bonus coolness, add "-i" (it prints the lines and highlights the current word during reading).