Re: [PATCH] mergetool: Skip autoresolved paths
- From
Jonathan Nieder <jrnieder@gmail.com>
- Date
- Aug 20, 2010, 10:09 UTC
- Message-ID
- <20100820100957.GB32127@burratino>
- In-Reply-To
- <4C6E519E.1080700@hashpling.org>
Charles Bailey wrote:
> We're in the middle of a shell pipe which has replaced stdin and > merge_file needs access to the human on it's stdin; hence the > </dev/tty. Strictly.
[...]
> Is there some way of juggling file descriptors in shell?
You can duplicate important fds, like so:
exec 3<&0
foo | ( bar baz quuz <&3 )
> I had a > quick play with this but suspect it's a bashism
It's standard, luckily. See http://unix.org/2008edition/
Hope that helps.