Re: [PATCH] Add git-bundle - pack objects and references for disconnected transfer
- From
Junio C Hamano <junkio@cox.net>
- Date
- Feb 16, 2007, 07:28 UTC
- Message-ID
- <7vd54aa7dr.fsf@assigned-by-dhcp.cox.net>
- In-Reply-To
- <20070216044158.GB28894@spearce.org>
"Shawn O. Pearce" <spearce@spearce.org> writes:
> Using "test" is a style thing, but using "=" rather than "==" is > a portability issue. "==" is accepted by bash as a synonym for > "=", but its not valid elsewhere.
True, I should have stressed that. Thanks. Also in the same sense (but to a lessor degree), "test" vs "[" is also portability issue.
Show 7 quoted lines
> What about: > > parents="$parents $(git-rev-list --max-count=1 --parents $c | cut -b42-)" > > I just used that trick recently. Oh yea it was in git-gui's > GIT-VERSION-GEN script. Though I did not know about using cut > like that...
I used to stay away from 'cut' myself, although it is not too bad for portability these days. I would probably have done the above with a single sed process, though.