diff <(man -a -l $HOME/SciYAG/ctioga/doc/ctioga.1 | \ egrep -o -- '--[a-z0-9-]+' | sort | uniq) \ <(ctioga --help | egrep -o -- '--[][a-z0-9-]+' | \ sort | uniq) | colordiff | less -R
(of course, I broke it into lines for clarity). It is based on process substitution, a shell trick that lets you use the output/input of a shell command exactly as a file on command line. Neat ! The trouble is, replacing the colordiff...
part by | egrep '^>' | wc
tells me there are 65 undocumented features... Lots of work in perspective, and I'm not sure I'll do it all before the 1.9 release...
1 comment:
Indeed.. I use diff <(prog file1) <(prog file2) all the time.
zsh also has a =() which uses real temporary files instead of pipes.
Post a Comment