Re: [PATCH v3] fast-import: add 'ls' command
- From
Jonathan Nieder <jrnieder@gmail.com>
- Date
- Feb 12, 2011, 01:36 UTC
- Message-ID
- <20110212013643.GB24736@elie>
- In-Reply-To
- <20110212012153.GA24736@elie>
Jonathan Nieder wrote:
> It is probably be less confusing to use "missing" and let frontends > handle that rather shielding the frontend from reality. Like so:
^
This should say "rather than", as in: "It is confusing to lie to the frontend; let's not do that."
Side note: this adds some complication to frontends. For example, to copy some/path from the commit called :5, without this change, one could do
echo 'ls :5 some/path' read -r mode type dataref path echo "M $mode $dataref $path"
but now one would have to do:
echo 'ls :5 some/path'
read -r mode rest
case $mode in
missing)
echo "D some/path"
;;
*)
dataref=${rest#* }
echo "M $mode $dataref some/path"
;;
esacThe former is simpler; the latter is more explicit and probably less confusing.
Sorry for the nonsense. Jonathan