Re: git-bisect: weird usage of read(1)
- From
Johannes Schindelin <johannes.schindelin@gmx.de>
- Date
- Aug 11, 2008, 14:15 UTC
- Message-ID
- <alpine.DEB.1.00.0808111615260.24820@pacific.mpi-cbg.de.mpi-cbg.de>
- In-Reply-To
- <38b2ab8a0808110657y24ac9526wca4acea3bddaec00@mail.gmail.com>
Hi,
On Mon, 11 Aug 2008, Francis Moreau wrote:
Show 9 quoted lines
> I found this in git bisect: > > printf >&2 'Are you sure [Y/n]? ' > case "$(read yesno)" in [Nn]*) exit 1 ;; esac > > which looks very weird since read(1) returns a status and not the > string reads from std input. > > Am I missing something ?
Yes. "$()" does not return the status, but the output.
Ciao, Dscho