From: David Michael Barr Date: Thu, 02 Dec 2010 12:57:18 GMT Subject: Re: [PATCH] fast-import: add 'ls' command Message-ID: <2F775519-BF60-4885-BAC1-1A09F7E0D9B2@cordelta.com> In-Reply-To: Hi Sverre, >> There are two forms of the 'ls' command, one that takes a tree-ish and >> one relative to the index. Allow the tree-ish variant to be used anywhere >> a comment is allowed. Allow the index variant to be used within a commit >> where file change commands would be used. > > The commit message doesn't explain why the index variant isn't allowed > anywhere a comment is allowed. I assume that's because there's a > half-constructed index if you're in the middle of a modify operation > or such? The index variant is allowed between file change commands, at which the index should be consistent albeit deferred for hashing. I believe this is the only place where there's naturally an implicit active tree. Simply, "relative to the index" only makes sense when describing a commit. Unfortunately, the list server dropped my summary email :( The patch was supposed to be marked as a RFC and I gave an outline of the intended use. The key features I need for svn-fe are access to the index for the current commit and access to the content of older marked commits. NB: This version doesn't support unquoted paths. -- David Barr