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

[Bug] git status -unormal -- 'foo[b]/' won't display content of 'foo[b]/

From
Rémi Vanicat <vanicat@debian.org>
Date
Sep 21, 2014, 18:04 UTC
Message-ID
<87vbogq293.dlv@gmail.com>
Hello,

I found what look like a bug in git status: `git status -unormal foo[b]/` won't output the content of the directory foo[b] when `git status -unormal foo/` will output the content of the directory foo:

  $ mkdir 'foo[b]'
  $ touch 'foo[b]/bar'
  $ git status -unormal 'foo[b]/'
  On branch master
  Untracked files:
    (use "git add <file>..." to include in what will be committed)
          foo[b]/
  nothing added to commit but untracked files present (use "git add" to track)
  $ mkdir 'foo'
  $ touch 'foo/bar'
  $ git status -unormal 'foo/'
  On branch master
  Untracked files:
    (use "git add <file>..." to include in what will be committed)
          foo/bar
  nothing added to commit but untracked files present (use "git add" to track)

The documentation of git status contain nothing about treating bracket specially. Quoting the brackets do not solve the problem.

see https://github.com/magit/magit/issues/1512 for discussion about it (in the case of git status --porcelain).

-- 
Rémi Vanicat
Next: Torsten Bögershausen
Message 1 of 4 in “[Bug] git status -unormal -- 'foo[b]/' won't display content of 'foo[b]/”
  1. Rémi VanicatSep 21, 2014
  2. Torsten BögershausenSep 21, 2014
  3. Duy NguyenSep 22, 2014
  4. Duy NguyenSep 22, 2014

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.