From: Matthieu Moy <Matthieu.Moy@grenoble-inp.fr>
To: Javier.Roucher-Iglesias@ensimag.imag.fr
Cc: git@vger.kernel.org, Javier Roucher <jroucher@gmail.com>
Subject: Re: [PATCH/RFC] add git credential login to remote mediawiki
Date: Tue, 12 Jun 2012 16:51:18 +0200 [thread overview]
Message-ID: <vpq8vfsoa6x.fsf@bauges.imag.fr> (raw)
In-Reply-To: <1339512125-32761-1-git-send-email-Javier.Roucher-Iglesias@ensimag.imag.fr> (Javier Roucher-Iglesias's message of "Tue, 12 Jun 2012 16:42:05 +0200")
Javier.Roucher-Iglesias@ensimag.imag.fr writes:
> # MediaWiki API instance, created lazily.
> +sub run_credential {
How is the code related to the comment right above?
> + my $Prog = "git credential $op";
> + open2 (*Reader, *Writer, $Prog);
> + print Writer $msg;
> + close (Writer);
No space before "(" for function calls (already mentionned twice).
> my $mediawiki;
Didn't I already mention (twice?) that this declaration was meant to
stay right above mw_connect_maybe?
> + run_credential("reject");
> +# exit 1;
Do you, or do you not want to "exit 1". Either remove this, or uncomment
it.
> sub mw_connect_maybe {
> +
> if ($mediawiki) {
Why do you add this blank line? (already mentionned)
> - if ($wiki_login) {
> - 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";
> - print STDERR "(error " .
> - $mediawiki->{error}->{code} . ': ' .
> - $mediawiki->{error}->{details} . ")\n";
> - exit 1;
> - } else {
> - print STDERR "Logged in with user \"$wiki_login\".\n";
> - }
> - }
> + ask_credential();
This means you can't use the wiki anonymously anymore. This is an
unacceptable regression.
--
Matthieu Moy
http://www-verimag.imag.fr/~moy/
next prev parent reply other threads:[~2012-06-12 14:52 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-06-12 14:42 [PATCH/RFC] add git credential login to remote mediawiki Javier.Roucher-Iglesias
2012-06-12 14:51 ` Matthieu Moy [this message]
2012-06-12 15:10 ` roucherj
2012-06-12 15:21 ` Matthieu Moy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=vpq8vfsoa6x.fsf@bauges.imag.fr \
--to=matthieu.moy@grenoble-inp.fr \
--cc=Javier.Roucher-Iglesias@ensimag.imag.fr \
--cc=git@vger.kernel.org \
--cc=jroucher@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox