From: Jonathan Nieder Date: Fri, 20 Aug 2010 10:09:57 GMT Subject: Re: [PATCH] mergetool: Skip autoresolved paths 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 > 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.