Re: [PATCH v2] add git credential login to remote mediawiki
On Tue, 12 Jun 2012 10:44:40 +0200, Simon Perrat wrote:
Show 14 quoted lines
> 2012/6/11 <Javier.Roucher-Iglesias@ensimag.imag.fr>
>
>> + if ($op eq "fill") {
>> + while (<Reader>) {
>> + my ($key, $value) = /([^=]*)=(.*)/;
>> + # error if key undef
>> + if (not defined $key) {
>> + print STDERR "ERROR reciving reponse
>> git
>> credential fill\n";
>
> rec*eiving re*sponse
>
>Show 14 quoted lines
>> +sub ask_login {
>> + run_credential("fill");
>> +
>> + if (!$mediawiki->login( {
>> + lgname => $wiki_login,
>> + lgpassword => $wiki_passwd,
>> + lgdomain => $wiki_domain,
>> + } )) {
>> + print STDERR "Failed to log in mediawiki
>> user
>> \"$wiki_login\" on $url\n";
>
> Is there a reason for escaping $wiki_login alone ?
>Ok, i have changed the message now there is no quotes
>> + print STDERR "URL:$wiki_domain $url\n";
>
> Space after :
>
Show 6 quoted lines
>> + print STDERR "(error " .
>> + $mediawiki->{error}->{code} . ': ' .
>> + $mediawiki->{error}->{details} . ")\n";
>
> Broken indentation
>Show 9 quoted lines
>> + if (!$wiki_passwd) {
>> + #user knows, password not.
>> + ask_login();
>
> know*n (other instances below)
> and don't forget space after # ;)
>
>
> Best regards.