git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Shouldn't git-ls-files --others use $GIT_DIR?

From
Nikolai Weibull <now@bitwi.se>
Date
Nov 20, 2006, 19:51 UTC
Message-ID
<dbfc82860611201151m52933720lfef939b7f6803411@mail.gmail.com>
In-Reply-To
<20061119183756.GZ7201@pasky.or.cz>
On 11/19/06, Petr Baudis <pasky@suse.cz> wrote:
Show 12 quoted lines
> On Sun, Nov 19, 2006 at 02:37:42PM CET, Nikolai Weibull wrote:
> > If I do
> >
> > GIT_DIR=$HOME/projects/<project>/.git git ls-files --others
> >
> > from, e.g., $HOME, I get a list of all the files in $HOME and its
> > subdirectories that aren't in said git repository.  Shouldn't --others
> > use $GIT_DIR, instead of ".", or am I missing something here?
>
> git-ls-files --others lists untracked files in the current directory by
> comparing it to the index stored in $GIT_DIR/index and listing files
> present in the current directory but not in the index.
Ah, of course; how silly of me.  Thanks.
Previous: Petr Baudis
Message 3 of 3 in “Shouldn't git-ls-files --others use $GIT_DIR?”
  1. Nikolai WeibullNov 19, 2006
  2. Petr BaudisNov 19, 2006
  3. Nikolai WeibullNov 20, 2006

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.