{"thread":{"id":"26811","subject":"[PATCH] git-completion: Add git help completion for aliases","startedAt":"2011-03-21T09:25:06Z","lastAt":"2011-03-23T12:16:28Z","messageCount":19,"participants":["Jakob Pfender","Junio C Hamano","Johannes Schindelin","SZEDER Gábor","Erik Faye-Lund","Michael J Gruber","Jakub Narebski"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"163876","messageId":"4D871972.7080008@elegosoft.com","threadId":"26811","inReplyTo":null,"subject":"[PATCH] git-completion: Add git help completion for aliases","fromName":"Jakob Pfender","fromEmail":"jpfender@elegosoft.com","sentAt":"2011-03-21T09:25:06Z","receivedAt":"2011-03-21T09:25:06Z","isPatch":true,"sender":{"key":"jpfender@elegosoft.com","avatar":null},"body":"Enable bash completion for \"git help <alias>\", analogous to \"git\n<alias>\", which was already implemented.\n\nSigned-off-by: Jakob Pfender <jpfender@elegosoft.com>\n---\n  contrib/completion/git-completion.bash |    2 +-\n  1 files changed, 1 insertions(+), 1 deletions(-)\n\ndiff --git a/contrib/completion/git-completion.bash \nb/contrib/completion/git-completion.bash\nindex 893b771..f9a74d3 100755\n--- a/contrib/completion/git-completion.bash\n+++ b/contrib/completion/git-completion.bash\n@@ -1506,7 +1506,7 @@ _git_help ()\n  \t\t;;\n  \tesac\n  \t__git_compute_all_commands\n-\t__gitcomp \"$__git_all_commands\n+\t__gitcomp \"$__git_all_commands $(__git_aliases)\n  \t\tattributes cli core-tutorial cvs-migration\n  \t\tdiffcore gitk glossary hooks ignore modules\n  \t\trepository-layout tutorial tutorial-2\n-- \n1.7.0.4\n"},{"id":"163987","messageId":"7vhbawno11.fsf@alter.siamese.dyndns.org","threadId":"26811","inReplyTo":"4D871972.7080008@elegosoft.com","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2011-03-21T21:48:10Z","receivedAt":"2011-03-21T21:48:10Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Jakob Pfender <jpfender@elegosoft.com> writes:\n\n> Enable bash completion for \"git help <alias>\", analogous to \"git\n> <alias>\", which was already implemented.\n>\n> Signed-off-by: Jakob Pfender <jpfender@elegosoft.com>\n> ---\n>  contrib/completion/git-completion.bash |    2 +-\n>  1 files changed, 1 insertions(+), 1 deletions(-)\n>\n> diff --git a/contrib/completion/git-completion.bash\n> b/contrib/completion/git-completion.bash\n> index 893b771..f9a74d3 100755\n> --- a/contrib/completion/git-completion.bash\n> +++ b/contrib/completion/git-completion.bash\n> @@ -1506,7 +1506,7 @@ _git_help ()\n>  \t\t;;\n>  \tesac\n>  \t__git_compute_all_commands\n> -\t__gitcomp \"$__git_all_commands\n> +\t__gitcomp \"$__git_all_commands $(__git_aliases)\n>  \t\tattributes cli core-tutorial cvs-migration\n>  \t\tdiffcore gitk glossary hooks ignore modules\n>  \t\trepository-layout tutorial tutorial-2\n\nThis patch may not be _wrong_ per-se, but it it useful in practice?\n\nI dunno.\n\nDon't people usually use aliases so that they do not have to type long\ncommand names that would need completion?\n"},{"id":"163992","messageId":"alpine.DEB.1.00.1103212302000.1561@bonsai2","threadId":"26811","inReplyTo":"7vhbawno11.fsf@alter.siamese.dyndns.org","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2011-03-21T22:07:15Z","receivedAt":"2011-03-21T22:07:15Z","isPatch":true,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Mon, 21 Mar 2011, Junio C Hamano wrote:\n\n> Jakob Pfender <jpfender@elegosoft.com> writes:\n> \n> > Enable bash completion for \"git help <alias>\", analogous to \"git\n> > <alias>\", which was already implemented.\n> >\n> > Signed-off-by: Jakob Pfender <jpfender@elegosoft.com>\n> > ---\n> >  contrib/completion/git-completion.bash |    2 +-\n> >  1 files changed, 1 insertions(+), 1 deletions(-)\n> >\n> > diff --git a/contrib/completion/git-completion.bash\n> > b/contrib/completion/git-completion.bash\n> > index 893b771..f9a74d3 100755\n> > --- a/contrib/completion/git-completion.bash\n> > +++ b/contrib/completion/git-completion.bash\n> > @@ -1506,7 +1506,7 @@ _git_help ()\n> >  \t\t;;\n> >  \tesac\n> >  \t__git_compute_all_commands\n> > -\t__gitcomp \"$__git_all_commands\n> > +\t__gitcomp \"$__git_all_commands $(__git_aliases)\n> >  \t\tattributes cli core-tutorial cvs-migration\n> >  \t\tdiffcore gitk glossary hooks ignore modules\n> >  \t\trepository-layout tutorial tutorial-2\n> \n> This patch may not be _wrong_ per-se, but it it useful in practice?\n> \n> I dunno.\n> \n> Don't people usually use aliases so that they do not have to type long\n> command names that would need completion?\n\nYes. And if you use a lot of aliases, or a lot of machines with evolving \naliases, the easiest way to inspect the alias is \"git help <alias>\". Not \nseeing it completed is an unexpected behavior.\n\nGit is moving the right direction in terms of user-friendliness, e.g. by \nDWIMming \"git checkout <remote branch>\". Adding this completion would be \na small step in the same direction, not more.\n\nCiao,\nJohannes\n"},{"id":"164018","messageId":"7v4o6vmvzs.fsf@alter.siamese.dyndns.org","threadId":"26811","inReplyTo":"alpine.DEB.1.00.1103212302000.1561@bonsai2","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2011-03-22T07:53:43Z","receivedAt":"2011-03-22T07:53:43Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:\n\n>> > diff --git a/contrib/completion/git-completion.bash\n>> > b/contrib/completion/git-completion.bash\n>> > index 893b771..f9a74d3 100755\n>> > --- a/contrib/completion/git-completion.bash\n>> > +++ b/contrib/completion/git-completion.bash\n>> > @@ -1506,7 +1506,7 @@ _git_help ()\n>> >  \t\t;;\n>> >  \tesac\n>> >  \t__git_compute_all_commands\n>> > -\t__gitcomp \"$__git_all_commands\n>> > +\t__gitcomp \"$__git_all_commands $(__git_aliases)\n>> >  \t\tattributes cli core-tutorial cvs-migration\n>> >  \t\tdiffcore gitk glossary hooks ignore modules\n>> >  \t\trepository-layout tutorial tutorial-2\n>> \n>> This patch may not be _wrong_ per-se, but it it useful in practice?\n>> \n>> I dunno.\n>> \n>> Don't people usually use aliases so that they do not have to type long\n>> command names that would need completion?\n>\n> Yes. And if you use a lot of aliases, or a lot of machines with evolving \n> aliases, the easiest way to inspect the alias is \"git help <alias>\". Not \n> seeing it completed is an unexpected behavior.\n\nI've queued the patch and I already said that this is not wrong, but I\nthink your argument cuts it both ways.\n\nI have \"co\" aliased to \"checkout\", but with this change \"git help co<TAB>\"\nnow will interfere with my expectation that it would complete to commit,\nconfig and the like, but exclude an alias that I myself defined and know\nhow to spell but forgot what its exact definition was, in order to avoid\ncluttering the choices offered.\n\nThis is a constructive tangent but if we are going to run $(__git_aliases)\nevery time we run _git_help, perhaps it would want a hack similar to the\nway the value for $__git_all_commands is generated just once?\n"},{"id":"164021","messageId":"20110322082355.GE14520@neumann","threadId":"26811","inReplyTo":"7vhbawno11.fsf@alter.siamese.dyndns.org","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"SZEDER Gábor","fromEmail":"szeder@ira.uka.de","sentAt":"2011-03-22T08:23:55Z","receivedAt":"2011-03-22T08:23:55Z","isPatch":true,"sender":{"key":"szeder.dev@gmail.com","avatar":"https://avatars.githubusercontent.com/u/116324?v=4"},"body":"On Mon, Mar 21, 2011 at 02:48:10PM -0700, Junio C Hamano wrote:\n> Jakob Pfender <jpfender@elegosoft.com> writes:\n> \n> > Enable bash completion for \"git help <alias>\", analogous to \"git\n> > <alias>\", which was already implemented.\n> >\n> > Signed-off-by: Jakob Pfender <jpfender@elegosoft.com>\n> > ---\n> >  contrib/completion/git-completion.bash |    2 +-\n> >  1 files changed, 1 insertions(+), 1 deletions(-)\n> >\n> > diff --git a/contrib/completion/git-completion.bash\n> > b/contrib/completion/git-completion.bash\n> > index 893b771..f9a74d3 100755\n> > --- a/contrib/completion/git-completion.bash\n> > +++ b/contrib/completion/git-completion.bash\n> > @@ -1506,7 +1506,7 @@ _git_help ()\n> >  \t\t;;\n> >  \tesac\n> >  \t__git_compute_all_commands\n> > -\t__gitcomp \"$__git_all_commands\n> > +\t__gitcomp \"$__git_all_commands $(__git_aliases)\n> >  \t\tattributes cli core-tutorial cvs-migration\n> >  \t\tdiffcore gitk glossary hooks ignore modules\n> >  \t\trepository-layout tutorial tutorial-2\n> \n> This patch may not be _wrong_ per-se, but it it useful in practice?\n> \n> I dunno.\n\nI think most people use 'git help <cmd>' to bring up the man page of\ngiven git command.  Since my aliases don't have a man page (and I\ndoubt that any alias will have one), I would never run 'git help\n<alias>' myself, because it would only lead to a 'man page not\navailable' error.  Well, at least so I thought, because I never knew\nthat 'git help <alias>' actually prints the definition of the alias.\nIt's definitely shorter and easier than 'git config --get\nalias.<alias>', but on the other hand it clutters 'git help <TAB>\noutput, especially if you have a lot of aliases.  If I had aliases\nlike 'ci' or 'co' instead of 'commit' and 'checkout', then I would\ndefinitely not want to see them after 'git help <TAB>'.\n\nSo I don't know either.\n\nSidenote: the completion for 'git help' already lists custom git\ncommands (i.e. a script named 'git-<cmd>' somewhere in $PATH'), and\nthose are likely not documented either.\n\n> Don't people usually use aliases so that they do not have to type long\n> command names that would need completion?\n\nI mostly use aliases for a command and a couple of options (e.g. a\ncustom log format), and give them meaningful names.\n\n\nBest,\nGábor\n"},{"id":"164022","messageId":"alpine.DEB.1.00.1103220943200.1561@bonsai2","threadId":"26811","inReplyTo":"7v4o6vmvzs.fsf@alter.siamese.dyndns.org","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2011-03-22T08:44:46Z","receivedAt":"2011-03-22T08:44:46Z","isPatch":true,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Tue, 22 Mar 2011, Junio C Hamano wrote:\n\n> Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:\n> \n> >> > diff --git a/contrib/completion/git-completion.bash\n> >> > b/contrib/completion/git-completion.bash\n> >> > index 893b771..f9a74d3 100755\n> >> > --- a/contrib/completion/git-completion.bash\n> >> > +++ b/contrib/completion/git-completion.bash\n> >> > @@ -1506,7 +1506,7 @@ _git_help ()\n> >> >  \t\t;;\n> >> >  \tesac\n> >> >  \t__git_compute_all_commands\n> >> > -\t__gitcomp \"$__git_all_commands\n> >> > +\t__gitcomp \"$__git_all_commands $(__git_aliases)\n> >> >  \t\tattributes cli core-tutorial cvs-migration\n> >> >  \t\tdiffcore gitk glossary hooks ignore modules\n> >> >  \t\trepository-layout tutorial tutorial-2\n> >> \n> >> This patch may not be _wrong_ per-se, but it it useful in practice?\n> >> \n> >> I dunno.\n> >> \n> >> Don't people usually use aliases so that they do not have to type long\n> >> command names that would need completion?\n> >\n> > Yes. And if you use a lot of aliases, or a lot of machines with evolving \n> > aliases, the easiest way to inspect the alias is \"git help <alias>\". Not \n> > seeing it completed is an unexpected behavior.\n> \n> I've queued the patch and I already said that this is not wrong, but I\n> think your argument cuts it both ways.\n> \n> I have \"co\" aliased to \"checkout\", but with this change \"git help \n> co<TAB>\" now will interfere with my expectation that it would complete \n> to commit, config and the like, but exclude an alias that I myself \n> defined and know how to spell but forgot what its exact definition was, \n> in order to avoid cluttering the choices offered.\n\nIn a corporate environment, one would now do a market research as to what \nis the common expectation.\n\n> This is a constructive tangent but if we are going to run \n> $(__git_aliases) every time we run _git_help, perhaps it would want a \n> hack similar to the way the value for $__git_all_commands is generated \n> just once?\n\nIndeed.\n\nCiao,\nJohannes\n"},{"id":"164023","messageId":"20110322085027.GF14520@neumann","threadId":"26811","inReplyTo":"7v4o6vmvzs.fsf@alter.siamese.dyndns.org","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"SZEDER Gábor","fromEmail":"szeder@ira.uka.de","sentAt":"2011-03-22T08:50:27Z","receivedAt":"2011-03-22T08:50:27Z","isPatch":true,"sender":{"key":"szeder.dev@gmail.com","avatar":"https://avatars.githubusercontent.com/u/116324?v=4"},"body":"On Tue, Mar 22, 2011 at 12:53:43AM -0700, Junio C Hamano wrote:\n> This is a constructive tangent but if we are going to run $(__git_aliases)\n> every time we run _git_help, perhaps it would want a hack similar to the\n> way the value for $__git_all_commands is generated just once?\n\nI think this is not necessary.  We already run __git_aliases() every\ntime after 'git <TAB>', and it was not an issue so far.  And indeed, I\njust created 50 aliases, and the time required for __git_aliases()\nseems to be negligible:\n\n  $ time __git_aliases\n  <bunch of aliases>\n\n  real    0m0.028s\n  user    0m0.016s\n  sys     0m0.004s\n\nBesides, invoking __git_aliases() every time has the benefit that\nnewly added aliases will appear immediately in completion suggestions.\n\n\nBest,\nGábor\n"},{"id":"164026","messageId":"AANLkTi=zbsNxLSCcWQorZCnRFuDPujqYzW7B0xJx2FHp@mail.gmail.com","threadId":"26811","inReplyTo":"20110322085027.GF14520@neumann","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"Erik Faye-Lund","fromEmail":"kusmabite@gmail.com","sentAt":"2011-03-22T09:16:16Z","receivedAt":"2011-03-22T09:16:16Z","isPatch":true,"sender":{"key":"kusmabite@gmail.com","avatar":"https://avatars.githubusercontent.com/u/47073?v=4"},"body":"2011/3/22 SZEDER Gábor <szeder@ira.uka.de>:\n> On Tue, Mar 22, 2011 at 12:53:43AM -0700, Junio C Hamano wrote:\n>> This is a constructive tangent but if we are going to run $(__git_aliases)\n>> every time we run _git_help, perhaps it would want a hack similar to the\n>> way the value for $__git_all_commands is generated just once?\n>\n> I think this is not necessary.  We already run __git_aliases() every\n> time after 'git <TAB>', and it was not an issue so far.  And indeed, I\n> just created 50 aliases, and the time required for __git_aliases()\n> seems to be negligible:\n>\n>  $ time __git_aliases\n>  <bunch of aliases>\n>\n>  real    0m0.028s\n>  user    0m0.016s\n>  sys     0m0.004s\n>\n\nUnfortunately, the situation is not quite so good on Windows:\n$ time __git_aliases\n<bunch of aliases>\n\nreal    0m0.112s\nuser    0m0.030s\nsys     0m0.015s\n\nThis is with 50 aliases, with 0 aliases I get this:\n$ time __git_aliases\ntest\n\nreal    0m0.063s\nuser    0m0.015s\nsys     0m0.015s\n"},{"id":"164027","messageId":"AANLkTimg74nh5C74tTXNQeK1nZnQVhGfH=gh8t1Nwr4j@mail.gmail.com","threadId":"26811","inReplyTo":"AANLkTi=zbsNxLSCcWQorZCnRFuDPujqYzW7B0xJx2FHp@mail.gmail.com","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"Erik Faye-Lund","fromEmail":"kusmabite@gmail.com","sentAt":"2011-03-22T09:18:30Z","receivedAt":"2011-03-22T09:18:30Z","isPatch":true,"sender":{"key":"kusmabite@gmail.com","avatar":"https://avatars.githubusercontent.com/u/47073?v=4"},"body":"2011/3/22 Erik Faye-Lund <kusmabite@gmail.com>:\n> 2011/3/22 SZEDER Gábor <szeder@ira.uka.de>:\n>> On Tue, Mar 22, 2011 at 12:53:43AM -0700, Junio C Hamano wrote:\n>>> This is a constructive tangent but if we are going to run $(__git_aliases)\n>>> every time we run _git_help, perhaps it would want a hack similar to the\n>>> way the value for $__git_all_commands is generated just once?\n>>\n>> I think this is not necessary.  We already run __git_aliases() every\n>> time after 'git <TAB>', and it was not an issue so far.  And indeed, I\n>> just created 50 aliases, and the time required for __git_aliases()\n>> seems to be negligible:\n>>\n>>  $ time __git_aliases\n>>  <bunch of aliases>\n>>\n>>  real    0m0.028s\n>>  user    0m0.016s\n>>  sys     0m0.004s\n>>\n>\n> Unfortunately, the situation is not quite so good on Windows:\n> $ time __git_aliases\n> <bunch of aliases>\n>\n> real    0m0.112s\n> user    0m0.030s\n> sys     0m0.015s\n>\n> This is with 50 aliases, with 0 aliases I get this:\n> $ time __git_aliases\n> test\n>\n> real    0m0.063s\n> user    0m0.015s\n> sys     0m0.015s\n>\n\nOK, apparently I have a dummy alias around from some time earlier, so\nthis was for 51 and 1 alias. But the point remains, it's actually a\nbit of a problem on Windows.\n"},{"id":"164028","messageId":"4D886A9E.6050405@drmicha.warpmail.net","threadId":"26811","inReplyTo":"7vhbawno11.fsf@alter.siamese.dyndns.org","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"Michael J Gruber","fromEmail":"git@drmicha.warpmail.net","sentAt":"2011-03-22T09:23:42Z","receivedAt":"2011-03-22T09:23:42Z","isPatch":true,"sender":{"key":"git@grubix.eu","avatar":"https://avatars.githubusercontent.com/u/233215?v=4"},"body":"Junio C Hamano venit, vidit, dixit 21.03.2011 22:48:\n> Jakob Pfender <jpfender@elegosoft.com> writes:\n> \n>> Enable bash completion for \"git help <alias>\", analogous to \"git\n>> <alias>\", which was already implemented.\n>>\n>> Signed-off-by: Jakob Pfender <jpfender@elegosoft.com>\n>> ---\n>>  contrib/completion/git-completion.bash |    2 +-\n>>  1 files changed, 1 insertions(+), 1 deletions(-)\n>>\n>> diff --git a/contrib/completion/git-completion.bash\n>> b/contrib/completion/git-completion.bash\n>> index 893b771..f9a74d3 100755\n>> --- a/contrib/completion/git-completion.bash\n>> +++ b/contrib/completion/git-completion.bash\n>> @@ -1506,7 +1506,7 @@ _git_help ()\n>>  \t\t;;\n>>  \tesac\n>>  \t__git_compute_all_commands\n>> -\t__gitcomp \"$__git_all_commands\n>> +\t__gitcomp \"$__git_all_commands $(__git_aliases)\n>>  \t\tattributes cli core-tutorial cvs-migration\n>>  \t\tdiffcore gitk glossary hooks ignore modules\n>>  \t\trepository-layout tutorial tutorial-2\n> \n> This patch may not be _wrong_ per-se, but it it useful in practice?\n> \n> I dunno.\n> \n> Don't people usually use aliases so that they do not have to type long\n> command names that would need completion?\n\nI'd say this would be a perfect argument for \"do not suggest aliases for\n'git <cmd>'\"; independent of that, we could still suggest aliases for\n'git help <cmd>' since, presumably, you use commands more often than you\nlook up help...\n\nBut currently, we do it the other way round, and even worse:\n\ngit for<TAB>\nfor-each-ref-do   format-patch\n\ngit help for<TAB>\nfor-each-ref   format-patch\n\nThat is, git command completion lists aliases (for-each-ref-do) and\ncommon commands, and git help completion lists no aliases and all commands.\n\nThe patch makes it so that the suggestions for git command are a subset\nof those for git help command, which is a good thing. (Not completing\naliases for 'git <cmd>' would be good also, on top of that.)\n\nAnd yes, I use git help <alias> a lot, because I don't like git config\n--get alias.<alias>, and our config files tend to grow in ugliness over\ntime. (We need git config --broomstick or git config --vacuum.)\n\nMichael\n"},{"id":"164030","messageId":"20110322100903.GG14520@neumann","threadId":"26811","inReplyTo":"AANLkTi=zbsNxLSCcWQorZCnRFuDPujqYzW7B0xJx2FHp@mail.gmail.com","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"SZEDER Gábor","fromEmail":"szeder@ira.uka.de","sentAt":"2011-03-22T10:09:03Z","receivedAt":"2011-03-22T10:09:03Z","isPatch":true,"sender":{"key":"szeder.dev@gmail.com","avatar":"https://avatars.githubusercontent.com/u/116324?v=4"},"body":"On Tue, Mar 22, 2011 at 10:16:16AM +0100, Erik Faye-Lund wrote:\n> 2011/3/22 SZEDER Gábor <szeder@ira.uka.de>:\n> > On Tue, Mar 22, 2011 at 12:53:43AM -0700, Junio C Hamano wrote:\n> >> This is a constructive tangent but if we are going to run $(__git_aliases)\n> >> every time we run _git_help, perhaps it would want a hack similar to the\n> >> way the value for $__git_all_commands is generated just once?\n> >\n> > I think this is not necessary.  We already run __git_aliases() every\n> > time after 'git <TAB>', and it was not an issue so far.  And indeed, I\n> > just created 50 aliases, and the time required for __git_aliases()\n> > seems to be negligible:\n> >\n> >  $ time __git_aliases\n> >  <bunch of aliases>\n> >\n> >  real    0m0.028s\n> >  user    0m0.016s\n> >  sys     0m0.004s\n> >\n> \n> Unfortunately, the situation is not quite so good on Windows:\n> $ time __git_aliases\n> <bunch of aliases>\n> \n> real    0m0.112s\n> user    0m0.030s\n> sys     0m0.015s\n> \n> This is with 50 aliases, with 0 aliases I get this:\n> $ time __git_aliases\n> test\n> \n> real    0m0.063s\n> user    0m0.015s\n> sys     0m0.015s\n\nI see.  However, on Windows everything git-related tends to be slow,\nso this is nothing new.\n\nThe question is whether the slowness of a known slow platform would\njustify the regression on all platforms.\n\n\nBest,\nGábor\n"},{"id":"164031","messageId":"AANLkTik8BaAJCnCRdDNTdu=nV1Q7cFLiwOuV_4wdXUE6@mail.gmail.com","threadId":"26811","inReplyTo":"20110322100903.GG14520@neumann","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"Erik Faye-Lund","fromEmail":"kusmabite@gmail.com","sentAt":"2011-03-22T10:28:01Z","receivedAt":"2011-03-22T10:28:01Z","isPatch":true,"sender":{"key":"kusmabite@gmail.com","avatar":"https://avatars.githubusercontent.com/u/47073?v=4"},"body":"2011/3/22 SZEDER Gábor <szeder@ira.uka.de>:\n> On Tue, Mar 22, 2011 at 10:16:16AM +0100, Erik Faye-Lund wrote:\n>> 2011/3/22 SZEDER Gábor <szeder@ira.uka.de>:\n>> > On Tue, Mar 22, 2011 at 12:53:43AM -0700, Junio C Hamano wrote:\n>> >> This is a constructive tangent but if we are going to run $(__git_aliases)\n>> >> every time we run _git_help, perhaps it would want a hack similar to the\n>> >> way the value for $__git_all_commands is generated just once?\n>> >\n>> > I think this is not necessary.  We already run __git_aliases() every\n>> > time after 'git <TAB>', and it was not an issue so far.  And indeed, I\n>> > just created 50 aliases, and the time required for __git_aliases()\n>> > seems to be negligible:\n>> >\n>> >  $ time __git_aliases\n>> >  <bunch of aliases>\n>> >\n>> >  real    0m0.028s\n>> >  user    0m0.016s\n>> >  sys     0m0.004s\n>> >\n>>\n>> Unfortunately, the situation is not quite so good on Windows:\n>> $ time __git_aliases\n>> <bunch of aliases>\n>>\n>> real    0m0.112s\n>> user    0m0.030s\n>> sys     0m0.015s\n>>\n>> This is with 50 aliases, with 0 aliases I get this:\n>> $ time __git_aliases\n>> test\n>>\n>> real    0m0.063s\n>> user    0m0.015s\n>> sys     0m0.015s\n>\n> I see.  However, on Windows everything git-related tends to be slow,\n> so this is nothing new.\n\nThat's not the case. Every thing Git-related isn't slow on Windows,\nbut there are some things in Git that is.\n\n> The question is whether the slowness of a known slow platform would\n> justify the regression on all platforms.\n>\n\nWindows isn't slow. Get over this way of thinking, it's just wrong.\nWindows has some different performance characteristics for some\noperations than e.g Linux, but saying that it's slow is just wrong.\nHowever, _Bash for Windows_ is quite slow, much due to Windows' lack\nof fork(), which means that some very involved emulation needs to be\nperformed.\n\nBut even so, at least 25% of the git user base is on Windows,\naccording to the latest Git User Survey. That makes this stuff matter.\n"},{"id":"164060","messageId":"4D88D0A2.7020003@drmicha.warpmail.net","threadId":"26811","inReplyTo":"AANLkTik8BaAJCnCRdDNTdu=nV1Q7cFLiwOuV_4wdXUE6@mail.gmail.com","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"Michael J Gruber","fromEmail":"git@drmicha.warpmail.net","sentAt":"2011-03-22T16:38:58Z","receivedAt":"2011-03-22T16:38:58Z","isPatch":true,"sender":{"key":"git@grubix.eu","avatar":"https://avatars.githubusercontent.com/u/233215?v=4"},"body":"Erik Faye-Lund venit, vidit, dixit 22.03.2011 11:28:\n> 2011/3/22 SZEDER Gábor <szeder@ira.uka.de>:\n>> On Tue, Mar 22, 2011 at 10:16:16AM +0100, Erik Faye-Lund wrote:\n>>> 2011/3/22 SZEDER Gábor <szeder@ira.uka.de>:\n>>>> On Tue, Mar 22, 2011 at 12:53:43AM -0700, Junio C Hamano wrote:\n>>>>> This is a constructive tangent but if we are going to run $(__git_aliases)\n>>>>> every time we run _git_help, perhaps it would want a hack similar to the\n>>>>> way the value for $__git_all_commands is generated just once?\n>>>>\n>>>> I think this is not necessary.  We already run __git_aliases() every\n>>>> time after 'git <TAB>', and it was not an issue so far.  And indeed, I\n>>>> just created 50 aliases, and the time required for __git_aliases()\n>>>> seems to be negligible:\n>>>>\n>>>>  $ time __git_aliases\n>>>>  <bunch of aliases>\n>>>>\n>>>>  real    0m0.028s\n>>>>  user    0m0.016s\n>>>>  sys     0m0.004s\n>>>>\n>>>\n>>> Unfortunately, the situation is not quite so good on Windows:\n>>> $ time __git_aliases\n>>> <bunch of aliases>\n>>>\n>>> real    0m0.112s\n>>> user    0m0.030s\n>>> sys     0m0.015s\n>>>\n>>> This is with 50 aliases, with 0 aliases I get this:\n>>> $ time __git_aliases\n>>> test\n>>>\n>>> real    0m0.063s\n>>> user    0m0.015s\n>>> sys     0m0.015s\n>>\n>> I see.  However, on Windows everything git-related tends to be slow,\n>> so this is nothing new.\n> \n> That's not the case. Every thing Git-related isn't slow on Windows,\n> but there are some things in Git that is.\n> \n>> The question is whether the slowness of a known slow platform would\n>> justify the regression on all platforms.\n>>\n> \n> Windows isn't slow. Get over this way of thinking, it's just wrong.\n> Windows has some different performance characteristics for some\n> operations than e.g Linux, but saying that it's slow is just wrong.\n> However, _Bash for Windows_ is quite slow, much due to Windows' lack\n> of fork(), which means that some very involved emulation needs to be\n> performed.\n> \n> But even so, at least 25% of the git user base is on Windows,\n> according to the latest Git User Survey. That makes this stuff matter.\n\n[Disclaimer: No, I don't like Win nor MS, but:]\n\nExactly, and the attitude which you criticise is a self-fulling prophecy\nif one follows it. We may break (or make things worse for) Git on\nWindows accidentally (because the percentage among developers is low),\nbut should never do so knowingly. And we may even try and watch out for\nthings which may be troublesome for Git on Win, and consult with our\nbrave Git on Win developers.\n\nMichael\n"},{"id":"164063","messageId":"7vsjufkqxl.fsf@alter.siamese.dyndns.org","threadId":"26811","inReplyTo":"20110322085027.GF14520@neumann","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2011-03-22T17:25:58Z","receivedAt":"2011-03-22T17:25:58Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"SZEDER Gábor <szeder@ira.uka.de> writes:\n\n> I think this is not necessary.  We already run __git_aliases() every\n> time after 'git <TAB>', and it was not an issue so far.\n\nIf we allow that line of reasoning, the cached $__git_all_commands that\ncan go stale needs to be removed, no?  I think folks running bash on\nwindows wanted it and it would be helping them.\n\nOne valid looking argument against caching aliases but still caching\ncommands is that the former could change on the end user's whim while the\nlatter is more or less stable across releases, but people can throw their\nown \"git-frotz\" in their path and run it as \"git frotz\", so that is not\nentirely a valid argument, either.\n"},{"id":"164085","messageId":"20110322202518.GA30604@neumann","threadId":"26811","inReplyTo":"AANLkTik8BaAJCnCRdDNTdu=nV1Q7cFLiwOuV_4wdXUE6@mail.gmail.com","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"SZEDER Gábor","fromEmail":"szeder@ira.uka.de","sentAt":"2011-03-22T20:25:18Z","receivedAt":"2011-03-22T20:25:18Z","isPatch":true,"sender":{"key":"szeder.dev@gmail.com","avatar":"https://avatars.githubusercontent.com/u/116324?v=4"},"body":"On Tue, Mar 22, 2011 at 11:28:01AM +0100, Erik Faye-Lund wrote:\n> 2011/3/22 SZEDER Gábor <szeder@ira.uka.de>:\n> > On Tue, Mar 22, 2011 at 10:16:16AM +0100, Erik Faye-Lund wrote:\n> >> 2011/3/22 SZEDER Gábor <szeder@ira.uka.de>:\n> >> > On Tue, Mar 22, 2011 at 12:53:43AM -0700, Junio C Hamano wrote:\n> >> >> This is a constructive tangent but if we are going to run $(__git_aliases)\n> >> >> every time we run _git_help, perhaps it would want a hack similar to the\n> >> >> way the value for $__git_all_commands is generated just once?\n> >> >\n> >> > I think this is not necessary.  We already run __git_aliases() every\n> >> > time after 'git <TAB>', and it was not an issue so far.  And indeed, I\n> >> > just created 50 aliases, and the time required for __git_aliases()\n> >> > seems to be negligible:\n> >> >\n> >> >  $ time __git_aliases\n> >> >  <bunch of aliases>\n> >> >\n> >> >  real    0m0.028s\n> >> >  user    0m0.016s\n> >> >  sys     0m0.004s\n> >> >\n> >>\n> >> Unfortunately, the situation is not quite so good on Windows:\n> >> $ time __git_aliases\n> >> <bunch of aliases>\n> >>\n> >> real    0m0.112s\n> >> user    0m0.030s\n> >> sys     0m0.015s\n> >>\n> >> This is with 50 aliases, with 0 aliases I get this:\n> >> $ time __git_aliases\n> >> test\n> >>\n> >> real    0m0.063s\n> >> user    0m0.015s\n> >> sys     0m0.015s\n> >\n> > I see.  However, on Windows everything git-related tends to be slow,\n> > so this is nothing new.\n> \n> That's not the case. Every thing Git-related isn't slow on Windows,\n> but there are some things in Git that is.\n> \n> > The question is whether the slowness of a known slow platform would\n> > justify the regression on all platforms.\n> >\n> \n> Windows isn't slow. Get over this way of thinking, it's just wrong.\n> Windows has some different performance characteristics for some\n> operations than e.g Linux, but saying that it's slow is just wrong.\n> However, _Bash for Windows_ is quite slow, much due to Windows' lack\n> of fork(), which means that some very involved emulation needs to be\n> performed.\n\nI meant the above only in the context of git, based on my last -- it\nseems outdated -- experiences with msysgit about (more than?) a year\nago, when I found such builtins like commit and checkout to be quite\nnoticeably slow.  I'm glad to hear that things are changing for good.\n\nAnyway, with the following silly \"benchmarking\" on top of the\nthread-starter patch[*] ...\n\n\ndiff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash\nindex d2b8746..12aa613 100755\n--- a/contrib/completion/git-completion.bash\n+++ b/contrib/completion/git-completion.bash\n@@ -2742,7 +2742,7 @@ _git ()\n \tfi\n \n \tlocal completion_func=\"_git_${command//-/_}\"\n-\tdeclare -f $completion_func >/dev/null && $completion_func && return\n+\tdeclare -f $completion_func >/dev/null && time $completion_func && return\n \n \tlocal expansion=$(__git_aliased_command \"$command\")\n \tif [ -n \"$expansion\" ]; then\n\n\n... the time required for 'git help <TAB>' with msysgit is around\n120-140ms.\n\nWith the caching of aliases for 'git help' ...\n\n\ndiff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash\nindex 12aa613..466578b 100755\n--- a/contrib/completion/git-completion.bash\n+++ b/contrib/completion/git-completion.bash\n@@ -963,6 +963,12 @@ __git_aliases ()\n \tdone\n }\n \n+__git_aliases=\n+__git_compute_aliases ()\n+{\n+\t: ${__git_aliases:=$(__git_aliases)}\n+}\n+\n # __git_aliased_command requires 1 argument\n __git_aliased_command ()\n {\n@@ -1508,7 +1514,8 @@ _git_help ()\n \t\t;;\n \tesac\n \t__git_compute_all_commands\n-\t__gitcomp \"$__git_all_commands $(__git_aliases)\n+\t__git_compute_aliases\n+\t__gitcomp \"$__git_all_commands $__git_aliases\n \t\tattributes cli core-tutorial cvs-migration\n \t\tdiffcore gitk glossary hooks ignore modules\n \t\trepository-layout tutorial tutorial-2\n\n... it goes down to around 50ms.\n\nLooking at the numbers it seems to be a significant improvement, but\nin practice I'm not sure I noticed anything; perhaps it's more\nnoticeable on slower hardware.  Just for the record, the numbers on\nlinux are ~50ms without and ~40ms with alias caching.\n\n> But even so, at least 25% of the git user base is on Windows,\n> according to the latest Git User Survey. That makes this stuff matter.\n\nThe other point of view is that it will cause a regression without a\ncompensating benefit for maybe more than 75% of the user base ;)\n\n\nBest,\nGábor\n\n\n[*] - off topic: Was it just me, or that simple patch really couldn't\nbe applied with a simple 'git am' on today's master?  What exactly\ncaused the conflict?  I looked quite hard, but couldn't find\nanything...\n"},{"id":"164090","messageId":"20110322212131.GB30604@neumann","threadId":"26811","inReplyTo":"7vsjufkqxl.fsf@alter.siamese.dyndns.org","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"SZEDER Gábor","fromEmail":"szeder@ira.uka.de","sentAt":"2011-03-22T21:21:31Z","receivedAt":"2011-03-22T21:21:31Z","isPatch":true,"sender":{"key":"szeder.dev@gmail.com","avatar":"https://avatars.githubusercontent.com/u/116324?v=4"},"body":"On Tue, Mar 22, 2011 at 10:25:58AM -0700, Junio C Hamano wrote:\n> SZEDER Gábor <szeder@ira.uka.de> writes:\n> \n> > I think this is not necessary.  We already run __git_aliases() every\n> > time after 'git <TAB>', and it was not an issue so far.\n> \n> If we allow that line of reasoning, the cached $__git_all_commands that\n> can go stale needs to be removed, no?  I think folks running bash on\n> windows wanted it and it would be helping them.\n\nWell, Shawn wrote that it was your request ;)\n\n  http://thread.gmane.org/gmane.comp.version-control.git/32444\n  http://thread.gmane.org/gmane.comp.version-control.git/32438\n\nBut there was indeed a remark shortly before that about bad fork-exec\nperformance under Cygwin on an other topic.\n\n> One valid looking argument against caching aliases but still caching\n> commands is that the former could change on the end user's whim while the\n> latter is more or less stable across releases,\n\nAgreed.\n\n> but people can throw their\n> own \"git-frotz\" in their path and run it as \"git frotz\"\n\nAlso agreed, and been annoyed by it not being recognized\nautomatically.  In fact I've even tried to make the completion script\ndetect user's commands on the fly but still without that huge loop\nover the 'git help -a' output in __git_list_porcelain_commands(), but\ncouldn't come up with anything acceptable so far.  And simply\nre-sourcing the completion script is not all that difficult,  which\nwill also take care of refreshing cached aliases, so...\n\n> so that is not\n> entirely a valid argument, either.\n\nagreed here, too.\n\n\nBest,\nGábor\n"},{"id":"164124","messageId":"AANLkTikLHRkE6aapS00q=4=4FSzjY1XQQQp=pRu12yP3@mail.gmail.com","threadId":"26811","inReplyTo":"20110322202518.GA30604@neumann","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"Erik Faye-Lund","fromEmail":"kusmabite@gmail.com","sentAt":"2011-03-23T10:32:18Z","receivedAt":"2011-03-23T10:32:18Z","isPatch":true,"sender":{"key":"kusmabite@gmail.com","avatar":"https://avatars.githubusercontent.com/u/47073?v=4"},"body":"2011/3/22 SZEDER Gábor <szeder@ira.uka.de>:\n> On Tue, Mar 22, 2011 at 11:28:01AM +0100, Erik Faye-Lund wrote:\n>> 2011/3/22 SZEDER Gábor <szeder@ira.uka.de>:\n>> > The question is whether the slowness of a known slow platform would\n>> > justify the regression on all platforms.\n>> >\n>>\n>> Windows isn't slow. Get over this way of thinking, it's just wrong.\n>> Windows has some different performance characteristics for some\n>> operations than e.g Linux, but saying that it's slow is just wrong.\n>> However, _Bash for Windows_ is quite slow, much due to Windows' lack\n>> of fork(), which means that some very involved emulation needs to be\n>> performed.\n>\n> I meant the above only in the context of git, based on my last -- it\n> seems outdated -- experiences with msysgit about (more than?) a year\n> ago, when I found such builtins like commit and checkout to be quite\n> noticeably slow.  I'm glad to hear that things are changing for good.\n\nActually, the situation isn't all that good, but it's mostly\ngit-completion.bash's fault:\n\n$ time __git_ps1 \"%s\"\nbuild-vbcc\nreal    0m0.162s\nuser    0m0.045s\nsys     0m0.000s\n\n150+ ms just to assemble what branch you're on does very much makes\nthings feel laggy. This affects even when yo just press enter.\n\nThis is especially annoying when just doing the meat of it directly is\nway cheaper:\n$ time git branch --no-color\n* master\n\nreal    0m0.036s\nuser    0m0.016s\nsys     0m0.000s\n\ngit commit in itself isn't that bad either:\n$ time git commit --allow-empty -m.\n[master 8d8d75e] .\n\nreal    0m0.051s\nuser    0m0.000s\nsys     0m0.015s\n\n50 ms for something that actually does something isn't that bad. And\nif it adds a non-empty commit, it's still OK:\n$ echo \"foo\" > test.txt\n$ git add test.txt\nwarning: LF will be replaced by CRLF in test.txt.\nThe file will have its original line endings in your working directory.\n$ time git commit -m \"bar\"\n[master 641c50e] bar\nwarning: LF will be replaced by CRLF in test.txt.\nThe file will have its original line endings in your working directory.\n 1 files changed, 1 insertions(+), 0 deletions(-)\n create mode 100644 test.txt\n\nreal    0m0.065s\nuser    0m0.015s\nsys     0m0.015s\n\n>> But even so, at least 25% of the git user base is on Windows,\n>> according to the latest Git User Survey. That makes this stuff matter.\n>\n> The other point of view is that it will cause a regression without a\n> compensating benefit for maybe more than 75% of the user base ;)\n>\n\nI don't think a minor regression like not getting bash-completion\nautomatically updated (something that only affects interactive use\nafter adding a new alias, and probably also could be fixed by adding a\n/tmp/git-completion.dirty.shell-pid file or something) should justify\ndegrading performance for an as large portion of users as the Windows\nusers are.\n\n(Warning: speculation ahead)\nAlso, I suspect the numbers of Windows developers are\nunderrepresented, for two reasons;\n- I suspect that Windows developers are less likely to be subscribed\nto the mailing lists where the Git User Survey are promoted.\n- I suspect that most Windows users use EITHER Cygwin OR MinGW, but I\nintentionally picked the largest of the Windows categories instead of\nadding them up because the Git User Survey allowed people to answer\nboth MinGW and Cygwin.\n\nUser Survey people, if your read this: please have a separate\noperating system question next year. It's very valuable information!\n"},{"id":"164133","messageId":"m3y646ujgy.fsf@localhost.localdomain","threadId":"26811","inReplyTo":"AANLkTikLHRkE6aapS00q=4=4FSzjY1XQQQp=pRu12yP3@mail.gmail.com","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"Jakub Narebski","fromEmail":"jnareb@gmail.com","sentAt":"2011-03-23T12:11:41Z","receivedAt":"2011-03-23T12:11:41Z","isPatch":true,"sender":{"key":"jnareb@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2706?v=4"},"body":"Erik Faye-Lund <kusmabite@gmail.com> writes:\n> 2011/3/22 SZEDER Gábor <szeder@ira.uka.de>:\n> > On Tue, Mar 22, 2011 at 11:28:01AM +0100, Erik Faye-Lund wrote:\n\n> > > But even so, at least 25% of the git user base is on Windows,\n> > > according to the latest Git User Survey. That makes this stuff matter.\n> >\n> > The other point of view is that it will cause a regression without a\n> > compensating benefit for maybe more than 75% of the user base ;)\n\n[...]\n> (Warning: speculation ahead)\n> Also, I suspect the numbers of Windows developers are\n> underrepresented, for two reasons;\n> - I suspect that Windows developers are less likely to be subscribed\n> to the mailing lists where the Git User Survey are promoted.\n> - I suspect that most Windows users use EITHER Cygwin OR MinGW, but I\n> intentionally picked the largest of the Windows categories instead of\n> adding them up because the Git User Survey allowed people to answer\n> both MinGW and Cygwin.\n> \n> User Survey people, if your read this: please have a separate\n> operating system question next year. It's very valuable information!\n\nThis information can be extracted from survey data, so there is no\nneed for separate question.\n\nPrior to adding this information to GitSurvey2010 page on git wiki,\n\n  https://git.wiki.kernel.org/index.php/GitSurvey2010#09._On_which_operating_system.28s.29_do_you_use_Git.3F\n  https://git.wiki.kernel.org/index.php?title=GitSurvey2010&diff=14112&oldid=12212\n\nyou could get this information by going to 'Analysis' page\n\n  http://tinyurl.com/GitSurvey2010Analysis\n\nselecting last filter: 'F13 - OS: MS Windows (any)', writing down\nnumber of responses: 2671, and calculating percentage relative to\nnumber of all responses to Q9, i.e. 8541, and you get 31.27% of\npeople using Git on MS Windows (not counting 'other, please specify'\nresponses, but they are very few).\n\nOr you could have extracted this information from responses data,\nwhich is available on GitSurvey2010 page...\n\n-- \nJakub Narebski\nPoland\nShadeHawk on #git\n"},{"id":"164135","messageId":"AANLkTikPoiC9qJ5WoTrO5PyetprD2O6CpQjPDsocxaQn@mail.gmail.com","threadId":"26811","inReplyTo":"m3y646ujgy.fsf@localhost.localdomain","subject":"Re: [PATCH] git-completion: Add git help completion for aliases","fromName":"Erik Faye-Lund","fromEmail":"kusmabite@gmail.com","sentAt":"2011-03-23T12:16:28Z","receivedAt":"2011-03-23T12:16:28Z","isPatch":true,"sender":{"key":"kusmabite@gmail.com","avatar":"https://avatars.githubusercontent.com/u/47073?v=4"},"body":"On Wed, Mar 23, 2011 at 1:11 PM, Jakub Narebski <jnareb@gmail.com> wrote:\n> Erik Faye-Lund <kusmabite@gmail.com> writes:\n>> 2011/3/22 SZEDER Gábor <szeder@ira.uka.de>:\n>> > On Tue, Mar 22, 2011 at 11:28:01AM +0100, Erik Faye-Lund wrote:\n>\n>> > > But even so, at least 25% of the git user base is on Windows,\n>> > > according to the latest Git User Survey. That makes this stuff matter.\n>> >\n>> > The other point of view is that it will cause a regression without a\n>> > compensating benefit for maybe more than 75% of the user base ;)\n>\n> [...]\n>> (Warning: speculation ahead)\n>> Also, I suspect the numbers of Windows developers are\n>> underrepresented, for two reasons;\n>> - I suspect that Windows developers are less likely to be subscribed\n>> to the mailing lists where the Git User Survey are promoted.\n>> - I suspect that most Windows users use EITHER Cygwin OR MinGW, but I\n>> intentionally picked the largest of the Windows categories instead of\n>> adding them up because the Git User Survey allowed people to answer\n>> both MinGW and Cygwin.\n>>\n>> User Survey people, if your read this: please have a separate\n>> operating system question next year. It's very valuable information!\n>\n> This information can be extracted from survey data, so there is no\n> need for separate question.\n>\n> Prior to adding this information to GitSurvey2010 page on git wiki,\n>\n>  https://git.wiki.kernel.org/index.php/GitSurvey2010#09._On_which_operating_system.28s.29_do_you_use_Git.3F\n>  https://git.wiki.kernel.org/index.php?title=GitSurvey2010&diff=14112&oldid=12212\n>\n> you could get this information by going to 'Analysis' page\n>\n>  http://tinyurl.com/GitSurvey2010Analysis\n>\n> selecting last filter: 'F13 - OS: MS Windows (any)', writing down\n> number of responses: 2671, and calculating percentage relative to\n> number of all responses to Q9, i.e. 8541, and you get 31.27% of\n> people using Git on MS Windows (not counting 'other, please specify'\n> responses, but they are very few).\n>\n> Or you could have extracted this information from responses data,\n> which is available on GitSurvey2010 page...\n>\n\nOK. Thanks for explaining this :)\n"}]}