gitk给出“参数列表太长”错误

Hao*_*hen 2 git

当我尝试使用“ gitk”打开一些大型仓库的历史记录的GUI时,总是出现“参数列表太长”错误。即使使用“ gitk -n”也不能解决问题。这里有人有同样的问题吗?谢谢,

couldn't execute "git": argument list too long
couldn't execute "git": argument list too long
    while executing
"open [concat $cmd $ids] r"
    (procedure "getallcommits" line 47)
    invoked from within
"getallcommits"
    (procedure "readcache" line 80)
    invoked from within
"readcache file13"
    ("eval" body line 1)
    invoked from within
"eval $script"
    (procedure "dorunq" line 11)
    invoked from within
"dorunq"
    ("after" script)
Run Code Online (Sandbox Code Playgroud)

Pet*_*etr 6

我在这里找到了一个工作.git/gitk.cache文件夹,它对我有用:只需删除文件即可。


tri*_*eee 2

当您在命令行上传递太多参数时,“参数列表太长”是一个内核错误。

可能您的存储库包含一些导致$ids(我纯粹在这里推测)超出ARG_MAX您平台限制的内容。

这基本上是 Gitk 中的一个错误,但如果您能找出导致此问题的资源,您可能可以通过以某种方式限制或修剪它来解决该问题。

  • 这似乎是试图解决这个问题,或者类似的问题——你的仓库有很多标签吗?http://git.vger.kernel.narkive.com/tDVsZzg7/patch-fix-gitk-with-lots-of-tags (2认同)