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

[REGRESSION] gitk can't be run from non-worktree folders

From
Cch <cr@onlinehome.de>
Date
Jan 23, 2020, 16:04 UTC
Message-ID
<4e2e5829-b9a7-b9b4-5605-ac28e8dbc45a@onlinehome.de>
Hi all!

I recently updated my Git installation from 2.24.1.windows.2 to 2.25.0.windows.1 and from the looks of it the included version of gitk does not support being run from non-worktree folders of a repository anymore (like the .git folder for example).

Here's a small reproduction recipe:
   $ git init repro
   $ cd repro
   $ git commit -m test --allow-empty
   $ cd .git
   $ gitk --all &
gitk terminates with the message:
   fatal: this operation must be run in a work tree
       while executing
   "exec git rev-parse --show-toplevel"
       invoked from within
   "set worktree [exec git rev-parse --show-toplevel]"
       (file "C:/Program Files/Git/mingw64/bin/gitk" line 12634)
-ch
Next: SZEDER Gábor
Message 1 of 15 in “[REGRESSION] gitk can't be run from non-worktree folders”
  1. chJan 23, 2020
  2. SZEDER GáborJan 23, 2020
  3. Eric SunshineJan 23, 2020
  4. SZEDER GáborJan 23, 2020
  5. SZEDER GáborJan 23, 2020
  6. Junio C HamanoJan 23, 2020
  7. gitk: to run in a bare repository (was: gitk can't be run from non-worktree folders)Junio C Hamano, Jan 23, 2020
  8. Eric SunshineJan 23, 2020
  9. Jeff KingJan 23, 2020
  10. chMar 30, 2020
  11. Eric SunshineOct 11, 2020
  12. chOct 13, 2020
  13. Pratyush YadavOct 13, 2020
  14. chApr 2, 2020
  15. Junio C HamanoApr 2, 2020

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.