Someone needs to explain to me in what parallel universe<p><pre><code> (sudo[ifconfig["-a"]] | grep["-i", "loop"]) & FG
</code></pre>
is more readable than<p><pre><code> sudo ifconfig -a | grep -i loop &</code></pre>
I'm sure it's convenient, but I wouldn't call this kind of operator overloading "pythonic".<p>Not to say being pythonic is always better, but some of these tricks don't even seem that practical. Why "& FG" instead of .fg()? Using division for joining paths is cute, but why not use '+', the conventional append operator?
This reminds me of when I first saw drop-box: Immediate recognition of the pain it will save me. I often hack up kludges that approximate this -- os.system calls that pipe to a file, then I read and parse the file. Good work.
I think this attempt and other simile are fun but I doubt I would use them for serious things. Maybe it should be done the other way: like markdown is an extension of html, we could have an extension of shell with python syntax.
While we're on the topic, here's another shell scripting package for Python: <a href="https://github.com/amoffat/pbs" rel="nofollow">https://github.com/amoffat/pbs</a>
Haskell has done it long ago and much better:<p><a href="http://news.ycombinator.com/item?id=3966630" rel="nofollow">http://news.ycombinator.com/item?id=3966630</a>