{"thread":{"id":"51967","subject":"[PATCH 0/1] gitk: Addressing error running on MacOS with large repos.","startedAt":"2019-10-03T20:49:13Z","lastAt":"2019-10-03T20:49:14Z","messageCount":2,"participants":["Arash via GitGitGadget","Arash Bannazadeh-Mahani via GitGitGadget"],"isPatch":true,"patchVersion":1,"patchTotal":1},"messages":[{"id":"383359","messageId":"pull.375.git.gitgitgadget@gmail.com","threadId":"51967","inReplyTo":null,"subject":"[PATCH 0/1] gitk: Addressing error running on MacOS with large repos.","fromName":"Arash via GitGitGadget","fromEmail":"gitgitgadget@gmail.com","sentAt":"2019-10-03T20:49:09Z","receivedAt":"2019-10-03T20:49:13Z","isPatch":true,"sender":{"key":"name:Arash","avatar":null},"body":"gitk: no need to specify all refs, since git log --all is the same as list\nis all the refs/commit ids. Also Mac OS has a limit on size of the list of\nparams for a command line\n\nArash Bannazadeh-Mahani (1):\n  gitk: Addressing error running on MacOS with large repos.\n\n gitk-git/gitk | 7 ++++++-\n 1 file changed, 6 insertions(+), 1 deletion(-)\n\n\nbase-commit: bc12974a897308fd3254cf0cc90319078fe45eea\nPublished-As: https://github.com/gitgitgadget/git/releases/tag/pr-375%2Faxbannaz%2Fuse.all-v1\nFetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-375/axbannaz/use.all-v1\nPull-Request: https://github.com/gitgitgadget/git/pull/375\n-- \ngitgitgadget\n"},{"id":"383360","messageId":"5594c953f0901f3f5643fc8003c37e37ea7221e7.1570135749.git.gitgitgadget@gmail.com","threadId":"51967","inReplyTo":"pull.375.git.gitgitgadget@gmail.com","subject":"[PATCH 1/1] gitk: Addressing error running on MacOS with large repos.","fromName":"Arash Bannazadeh-Mahani via GitGitGadget","fromEmail":"gitgitgadget@gmail.com","sentAt":"2019-10-03T20:49:10Z","receivedAt":"2019-10-03T20:49:14Z","isPatch":true,"sender":{"key":"name:Arash Bannazadeh-Mahani","avatar":null},"body":"From: Arash Bannazadeh-Mahani <axbannaz@gmail.com>\n\nThe change is stemmed from a problem on the MacOS where, if --all\nis passed to gitk it should show all the refs/commits graphically.\nHowever, on really large git repos, in my instance a git repo with\nover 52,000 commits, gitk will report an error,\n\"Error executing git log: couldn't execute \"git\": argument list too long\".\nMac OS has a limit of which my large repo exceeds. This works fine on Linux,\nhowever, not sure about Windows.\n\nLooking at gitk script, the decision to have all commit-ids on the command line\ncomes from return value of parseviewargs() function which uses the value of\n\"allknown\" to return. If it is '1' then --all is translated to a string of all\nthe commit-ids in the repo, otherwise --all is passed as-is to `git log` cli,\nwhich according to git-log man page it is the same as listing all the\ncommit-ids.\n\nSo, this change is to prevent --all option from being expanded into list\nof all refs on the command line.\n\nSigned-off-by: Arash Bannazadeh-Mahani <axbannaz@gmail.com>\n---\n gitk-git/gitk | 7 ++++++-\n 1 file changed, 6 insertions(+), 1 deletion(-)\n\ndiff --git a/gitk-git/gitk b/gitk-git/gitk\nindex abe4805ade..96634d9d33 100755\n--- a/gitk-git/gitk\n+++ b/gitk-git/gitk\n@@ -250,8 +250,13 @@ proc parseviewargs {n arglist} {\n \t\tset nextisval 1\n \t\tlappend glflags $arg\n \t    }\n-\t    \"--not\" - \"--all\" {\n+\t    \"--not\" {\n \t\tlappend revargs $arg\n+\t    }\n+\t\t\"--all\" {\n+\t\t# we recognize this argument;\n+\t\t# no expansion needed, use it with 'git log' as-is\n+\t\tset allknown 0\n \t    }\n \t    \"--merge\" {\n \t\tset vmergeonly($n) 1\n-- \ngitgitgadget\n"}]}