{"thread":{"id":"32575","subject":"git-completion.tcsh and git-completion.zsh are broken?","startedAt":"2013-01-09T19:17:11Z","lastAt":"2013-01-09T20:56:58Z","messageCount":3,"participants":["Manlio Perillo","Marc Khouzam"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"206403","messageId":"50EDC237.3000309@gmail.com","threadId":"32575","inReplyTo":null,"subject":"git-completion.tcsh and git-completion.zsh are broken?","fromName":"Manlio Perillo","fromEmail":"manlio.perillo@gmail.com","sentAt":"2013-01-09T19:17:11Z","receivedAt":"2013-01-09T19:17:11Z","isPatch":false,"sender":{"key":"manlio.perillo@gmail.com","avatar":"https://avatars.githubusercontent.com/u/6217088?v=4"},"body":"-----BEGIN PGP SIGNED MESSAGE-----\nHash: SHA1\n\nHi.\n\nI have finally resolved all the problems with my path completion in\ngit-completion.bash and, in order to avoid regressions, I'm checking the\ngit-completion.zsh and git-completion.tcsh scripts, since they use the\nbash completion support.\n\nI have installed (Debian 6.0.6):\n* zsh 4.3.10 (i686-pc-linux-gnu)\n* tcsh 6.17.02 (Astron) 2010-05-12 (i586-intel-linux)\n  options wide,nls,dl,al,kan,rh,nd,color,filec\n\nNote that I'm using my modified git-completion.bash script.\n\n\nzsh compatibility support in git-completion.bash seems to \"work\" (I just\nget a segmentation fault ...), however I have problems with the .zsh and\n.tcsh scripts.\n\n\n$zsh\nsynapsis% source contrib/completion/git-completion.zsh\n(anon):6: command not found: ___main\n_git:11: command not found: _default\n\nI have disabled compinit autoload (since, I don't know how, it is able\nto find the git completion script)\n\n\n$tcsh\nsynapsis:~/projects/git/contrib/git> source ~/.git-completion.tcsh\nsynapsis:~/projects/git/contrib/git> git show HEAD:<TAB>\n\ndoes not show the file list for the tree object in the HEAD\n\nanother problem is that a space is added after a directory name.\n\n\nAnother problem with zsh:\n\n$zsh\nsynapsis% git show HEAD:<TAB>569GPXZims\n\nI don't know where that 569GPXZims came from.\n\n\nCan someone else confirm these problems?\n\n\nThanks  Manlio\n-----BEGIN PGP SIGNATURE-----\nVersion: GnuPG v1.4.10 (GNU/Linux)\nComment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/\n\niEYEARECAAYFAlDtwjcACgkQscQJ24LbaURpuACfVQnoBC3tzvxB0JYxQ5aL3rmN\n8GEAnA7OjVtPqz+aq/PGtNtTHWgFqhKK\n=3UdZ\n-----END PGP SIGNATURE-----\n"},{"id":"206420","messageId":"E59706EF8DB1D147B15BECA3322E4BDC06B99D@eusaamb103.ericsson.se","threadId":"32575","inReplyTo":"50EDC237.3000309@gmail.com","subject":"RE: git-completion.tcsh and git-completion.zsh are broken?","fromName":"Marc Khouzam","fromEmail":"marc.khouzam@ericsson.com","sentAt":"2013-01-09T20:21:41Z","receivedAt":"2013-01-09T20:21:41Z","isPatch":false,"sender":{"key":"marc.khouzam@ericsson.com","avatar":"https://gravatar.com/avatar/de564e23ad14e2945f9f1cdb4d0227c935b5b54c39576a304d47caa3e23dcd33?d=mp&s=160"},"body":"\n> -----Original Message-----\n> From: git-owner@vger.kernel.org \n> [mailto:git-owner@vger.kernel.org] On Behalf Of Manlio Perillo\n> Sent: Wednesday, January 09, 2013 2:17 PM\n> To: git@vger.kernel.org\n> Subject: git-completion.tcsh and git-completion.zsh are broken?\n> \n> -----BEGIN PGP SIGNED MESSAGE-----\n> Hash: SHA1\n> \n> Hi.\n> \n> I have finally resolved all the problems with my path completion in\n> git-completion.bash and, in order to avoid regressions, I'm \n> checking the\n> git-completion.zsh and git-completion.tcsh scripts, since they use the\n> bash completion support.\n> \n> I have installed (Debian 6.0.6):\n> * zsh 4.3.10 (i686-pc-linux-gnu)\n> * tcsh 6.17.02 (Astron) 2010-05-12 (i586-intel-linux)\n>   options wide,nls,dl,al,kan,rh,nd,color,filec\n> \n> Note that I'm using my modified git-completion.bash script.\n> \n> \n> zsh compatibility support in git-completion.bash seems to \n> \"work\" (I just\n> get a segmentation fault ...), however I have problems with \n> the .zsh and\n> .tcsh scripts.\n> \n> \n> $zsh\n> synapsis% source contrib/completion/git-completion.zsh\n> (anon):6: command not found: ___main\n> _git:11: command not found: _default\n> \n> I have disabled compinit autoload (since, I don't know how, it is able\n> to find the git completion script)\n> \n> \n> $tcsh\n> synapsis:~/projects/git/contrib/git> source ~/.git-completion.tcsh\n> synapsis:~/projects/git/contrib/git> git show HEAD:<TAB>\n> \n> does not show the file list for the tree object in the HEAD\n\nHm.  That doesn't work for me either.  I'll look into it.\nIt is not caused by your changes.\n\n> another problem is that a space is added after a directory name.\n\nThe lastest version of git-completion.tcsh in the pu branch should\nfix that problem.  It was committed yesterday so you may not have it.\n\n> \n> \n> Another problem with zsh:\n> \n> $zsh\n> synapsis% git show HEAD:<TAB>569GPXZims\n> \n> I don't know where that 569GPXZims came from.\n> \n> \n> Can someone else confirm these problems?\n> \n> \n> Thanks  Manlio\n> -----BEGIN PGP SIGNATURE-----\n> Version: GnuPG v1.4.10 (GNU/Linux)\n> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/\n> \n> iEYEARECAAYFAlDtwjcACgkQscQJ24LbaURpuACfVQnoBC3tzvxB0JYxQ5aL3rmN\n> 8GEAnA7OjVtPqz+aq/PGtNtTHWgFqhKK\n> =3UdZ\n> -----END PGP SIGNATURE-----\n> --\n> To unsubscribe from this list: send the line \"unsubscribe git\" in\n> the body of a message to majordomo@vger.kernel.org\n> More majordomo info at  http://vger.kernel.org/majordomo-info.html\n> "},{"id":"206425","messageId":"50EDD99A.5090704@gmail.com","threadId":"32575","inReplyTo":"E59706EF8DB1D147B15BECA3322E4BDC06B99D@eusaamb103.ericsson.se","subject":"Re: git-completion.tcsh and git-completion.zsh are broken?","fromName":"Manlio Perillo","fromEmail":"manlio.perillo@gmail.com","sentAt":"2013-01-09T20:56:58Z","receivedAt":"2013-01-09T20:56:58Z","isPatch":false,"sender":{"key":"manlio.perillo@gmail.com","avatar":"https://avatars.githubusercontent.com/u/6217088?v=4"},"body":"-----BEGIN PGP SIGNED MESSAGE-----\nHash: SHA1\n\nIl 09/01/2013 21:21, Marc Khouzam ha scritto:\n> [...]\n> \n> $zsh\n> synapsis% source contrib/completion/git-completion.zsh\n> (anon):6: command not found: ___main\n> _git:11: command not found: _default\n> \n> I have disabled compinit autoload (since, I don't know how, it is able\n> to find the git completion script)\n> \n\nThe attached patch seems to fix it.\nI'm still getting segmentation faults, but only when I try to complete\ngit rm contrib/<TAB> (in the git repository).\n\nSorry if this is a plain patch.\nThe code is simply copied from the one found in git-completion.bash.\n\n\nI also noted that zsh on my system have preinstalled git completion\nsupport (enabled with autoload).\nThe code is not the one available in the git source tree.\nI don't know if the code is from Debian or zsh.\n\n> \n> $tcsh\n> synapsis:~/projects/git/contrib/git> source ~/.git-completion.tcsh\n> synapsis:~/projects/git/contrib/git> git show HEAD:<TAB>\n> \n> does not show the file list for the tree object in the HEAD\n> \n>> Hm.  That doesn't work for me either.  I'll look into it.\n>> It is not caused by your changes.\n> \n> another problem is that a space is added after a directory name.\n> \n>> The lastest version of git-completion.tcsh in the pu branch should\n>> fix that problem.  It was committed yesterday so you may not have it.\n> \n\nOk, thanks.\n\n\n\nRegards  Manlio\n-----BEGIN PGP SIGNATURE-----\nVersion: GnuPG v1.4.10 (GNU/Linux)\nComment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/\n\niEYEARECAAYFAlDt2ZoACgkQscQJ24LbaUR/ggCfYNbRrM1HzHWYDwkejNP/hD9k\nShkAnjv3JapVXPlj59CakY4kwaE/4z5J\n=qYP5\n-----END PGP SIGNATURE-----\n\n\ndiff --git a/contrib/completion/git-completion.zsh b/contrib/completion/git-completion.zsh\nindex 4577502..4aeda2a 100644\n--- a/contrib/completion/git-completion.zsh\n+++ b/contrib/completion/git-completion.zsh\n@@ -75,4 +75,5 @@ _git ()\n \treturn _ret\n }\n \n-_git\n+autoload -U +X compinit && compinit\n+compdef _git git gitk\n"}]}