← Back to team overview

vcs-fast-import-devs team mailing list archive

Re: [PATCH v3] fast-import: add 'ls' command

 

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"
		;;
	esac

The former is simpler; the latter is more explicit and probably less
confusing.

Sorry for the nonsense.
Jonathan



References