There is no need for use to manually call ‘git credential’ especially
as the interface isn’t super user-friendly and a bit confusing. ‘git
send-email’ will do that for them at the first execution and if the
password matches, it will be saved in the store.
Simplify the documentaion so it dosn’t in
First of all, ‘git credential fill’ does not store credentials
but is used to *read* them. The command which adds credentials
to the helper’s store is ‘git credential approve’.
Second of all, git-send-email will include port number in host
parameter when getting the password so it has to be set w
When git-send-email uses git-credential to get SMTP password, it will
communicate SMTP host and port (if both are provided) as a single entry
‘host=:’. This trips the ‘git-credential-store’ helper
which expects those values as separate keys (‘host’ and ‘port’).
Send the values as separate pieces
The get_pathname function does not really return path name but rather
a buffer to store pathname in. As such, current name is a bit
confusing. Change the name as to make it clearer what the function is
doing.
Signed-off-by: Michal Nazarewicz
---
path.c | 8
1 file changed, 4
The get_pathname function does not really return path name but rather
a buffer to store pathname in. As such, current name is a bit
confusing. Change the name as to make it clearer what the function is
doing.
Signed-off-by: Michal Nazarewicz
---
path.c | 8
1 file changed, 4
On Fri, Aug 23 2013, Junio C Hamano wrote:
> That is unfortunate, especially given the last line that the patch
> removes. Has anybody asked pastebin folks why it is gone and if it
> can be resurrected?
Way Back Machine has nothing.
What was under that link? If IRC logs, then those appear to be
From: Michal Nazarewicz
Signed-off-by: Michal Nazarewicz
---
Documentation/technical/pack-heuristics.txt | 6 --
1 file changed, 6 deletions(-)
diff --git a/Documentation/technical/pack-heuristics.txt
b/Documentation/technical/pack-heuristics.txt
index 8b7ae1c..b7bd951 100644
--- a
On Wed, Feb 27 2013, Junio C Hamano wrote:
> Matthieu Moy writes:
>
>> Michal Nazarewicz writes:
>>
>>> + $auth = Git::credential({
>>> + 'protocol' => 'smtp',
>>> + 'host' => join(':
On Tue, Feb 12 2013, Junio C Hamano wrote:
> I would actually vote for the most explicit:
>
> _cmd_close($ctx, (grep { defined } ($in, $out)));
To me that looks weird at best, but I don't have strong opinions on that
matter.
--
Best regards, _ _
On Tue, Feb 12 2013, Jeff King wrote:
> On Tue, Feb 12, 2013 at 03:02:31PM +0100, Michal Nazarewicz wrote:
>
>> sub command_close_bidi_pipe {
>> local $?;
>> my ($self, $pid, $in, $out, $ctx) = _maybe_self(@_);
>> -_cmd_close($ctx, $in, $out);
>>
>> Michal Nazarewicz writes:
>> > The body of the loop in command_close_bidi_pipe function is identical to
>> > what _cmd_close function does so instead of duplicating, refactor change
>> > _cmd_close so that it accepts list of file handlers to be closed, which
From: Michal Nazarewicz
The body of the loop in command_close_bidi_pipe function is identical to
what _cmd_close function does so instead of duplicating, refactor change
_cmd_close so that it accepts list of file handlers to be closed, which
makes it usable with command_close_bidi_pipe.
Signed
From: Michal Nazarewicz
Signed-off-by: Michal Nazarewicz
---
perl/Git.pm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/perl/Git.pm b/perl/Git.pm
index bbb753a..11f310a 100644
--- a/perl/Git.pm
+++ b/perl/Git.pm
@@ -418,7 +418,7 @@ and it is the fourth value returned by
From: Michal Nazarewicz
Add a credential() function which is an interface to the git
credential command. The code is heavily based on credential_*
functions in .
Signed-off-by: Michal Nazarewicz
---
perl/Git.pm | 151
1 file
From: Michal Nazarewicz
The documentation of command_close_bidi_pipe() claims that it can
be called as a method, but it does not check whether the first
argument is $self or not assuming the latter. Using _maybe_self()
fixes this.
Signed-off-by: Michal Nazarewicz
---
perl/Git.pm | 2 +-
1
From: Michal Nazarewicz
If smtp_user is provided but smtp_pass is not, instead of
prompting for password, make git-send-email use git
credential command instead.
Signed-off-by: Michal Nazarewicz
---
Documentation/git-send-email.txt | 4 +--
git-send-email.perl | 59
From: Michal Nazarewicz
Besids git-credential support in git-send-email, there are some other
minor improvements to Git.pm in this patchset. Patch 3/6 is new
compared to the previous patchset.
Michal Nazarewicz (6):
Git.pm: allow command_close_bidi_pipe to be called as method
Git.pm: fix
From: Michal Nazarewicz
The command_close_bidi_pipe() function will insist on closing both
input and output pipes returned by command_bidi_pipe(). With this
change it is possible to close one of the pipes in advance and
pass undef as an argument.
Signed-off-by: Michal Nazarewicz
---
perl
On Mon, Feb 11 2013, Jeff King wrote:
> Based on our discussion, I think it would just need the patch below
> squashed into your 4/5 (this handles the "undef" thing, and I also fixed
> a few typos in the API documentation):
> @@ -1152,7 +1155,9 @@ sub credential {
> if ('CODE' eq ref $op_or_
On Mon, Feb 11 2013, Jeff King wrote:
> I have two minor comments, which I'll reply inline with. But even with
> those comments, I think this would be OK to merge.
I'll send a new patchset tomorrow with.
--
Best regards, _ _
.o. | Liege of Serenely Enl
> On Mon, Feb 11, 2013 at 05:23:39PM +0100, Michal Nazarewicz wrote:
>> +# TODO: Authentication may fail not because credentials were
>> +# invalid but due to other reasons, in which we should not
>> +# reject credentials.
>> +$auth = Git::credential(
On Mon, Feb 11 2013, Jeff King wrote:
> On Mon, Feb 11, 2013 at 05:23:38PM +0100, Michal Nazarewicz wrote:
>
>> +=item credential_read( FILE_HANDLE )
>> +
>> +Reads credential key-value pairs from C. Reading stops at EOF
>> or
>> +when an empty line is encount
From: Michal Nazarewicz
If smtp_user is provided but smtp_pass is not, instead of
prompting for password, make git-send-email use git
credential command instead.
Signed-off-by: Michal Nazarewicz
---
Documentation/git-send-email.txt | 4 +--
git-send-email.perl | 59
From: Michal Nazarewicz
Add a credential() function which is an interface to the git
credential command. The code is heavily based on credential_*
functions in .
Signed-off-by: Michal Nazarewicz
---
perl/Git.pm | 148 +++-
1 file
From: Michal Nazarewicz
Signed-off-by: Michal Nazarewicz
---
perl/Git.pm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/perl/Git.pm b/perl/Git.pm
index bbb753a..11f310a 100644
--- a/perl/Git.pm
+++ b/perl/Git.pm
@@ -418,7 +418,7 @@ and it is the fourth value returned by
From: Michal Nazarewicz
The documentation of command_close_bidi_pipe() claims that it can
be called as a method, but it does not check whether the first
argument is $self or not assuming the latter. Using _maybe_self()
fixes this.
Signed-off-by: Michal Nazarewicz
---
perl/Git.pm | 2 +-
1
From: Michal Nazarewicz
The command_close_bidi_pipe() function will insist on closing both
input and output pipes returned by command_bidi_pipe(). With this
change it is possible to close one of the pipes in advance and
pass undef as an argument.
Signed-off-by: Michal Nazarewicz
---
perl
From: Michal Nazarewicz
The third version of the patch with changes suggested by Jeff in the
4/5 patch. Also credential_read and credential_write are now public
functions in case someone wants to write a helper in perl.
Michal Nazarewicz (5):
Git.pm: allow command_close_bidi_pipe to be
On Fri, Feb 08 2013, Junio C Hamano wrote:
> I'd actually be more worried about the error checking issue
> Peff raised during his review. I have a feeling that "when in doubt,
> do not cause harm" is a more prudent way to go than "I do not know,
> so I'll let anything pass".
I can implement whate
From: Michal Nazarewicz
If smtp_user is provided but smtp_pass is not, instead of
prompting for password, make git-send-email use git
credential command instead.
Signed-off-by: Michal Nazarewicz
---
Documentation/git-send-email.txt | 4 +--
git-send-email.perl | 59
From: Michal Nazarewicz
The command_close_bidi_pipe() function will insist on closing both
input and output pipes returned by command_bidi_pipe(). With this
change it is possible to close one of the pipes in advance and
pass undef as an argument.
Signed-off-by: Michal Nazarewicz
---
perl
From: Michal Nazarewicz
File handle goes as the first argument when calling print on it.
Signed-off-by: Michal Nazarewicz
---
perl/Git.pm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/perl/Git.pm b/perl/Git.pm
index bbb753a..11f310a 100644
--- a/perl/Git.pm
+++ b/perl
From: Michal Nazarewicz
Add a credential() function which is an interface to the git
credential command. The code is heavily based on credential_*
functions in .
Signed-off-by: Michal Nazarewicz
---
perl/Git.pm | 110 +++-
1 file
From: Michal Nazarewicz
The documentation of command_close_bidi_pipe() claims that it can
be called as a method, but it does not check whether the first
argument is $self or not assuming the latter. Using _maybe_self()
fixes this.
Signed-off-by: Michal Nazarewicz
---
perl/Git.pm | 2 +-
1
From: Michal Nazarewicz
Minor fixes as suggested in emails.
Michal Nazarewicz (5):
Git.pm: allow command_close_bidi_pipe to be called as method
Git.pm: fix example in command_close_bidi_pipe documentation
Git.pm: allow pipes to be closed prior to calling
command_close_bidi_pipe
From: Michal Nazarewicz
If smtp_user is provided but smtp_pass is not, instead of prompting
for password, make git-send-email use git credential command
instead.
Signed-off-by: Michal Nazarewicz
---
Documentation/git-send-email.txt | 4 +--
git-send-email.perl | 59
From: Michal Nazarewicz
Add a credential() function which is an interface to the
git credential command.
Signed-off-by: Michal Nazarewicz
---
perl/Git.pm | 112 +++-
1 file changed, 111 insertions(+), 1 deletion(-)
diff --git a/perl
From: Michal Nazarewicz
The documentation of command_close_bidi_pipe() claims that it can
be called as a method, but it does not check whether the first
argument is $self or not assuming the latter. Using _maybe_self()
fixes this.
Signed-off-by: Michal Nazarewicz
---
perl/Git.pm | 2 +-
1
From: Michal Nazarewicz
The command_close_bidi_pipe() function will insist on closing both
input and output pipes returned by command_bidi_pipe(). With this
change it is possible to close one of the pipes in advance and
pass undef as an argument.
This allows for something like:
my ($pid
From: Michal Nazarewicz
As discussed on the list, adding git-credential interface to Git.pm
(sort of copied from git-remote-mediawiki) and making git-send-email
use it.
I see git-remote-mediawiki does not have “use Git” so I did not touch
it. On top of that I'd have no way to tests the ch
On Wed, Feb 06 2013, Michal Nazarewicz wrote:
> As discussed on the list, adding git-credential interface to Git.pm
> (sort of copied from git-remote-mediawiki) and making git-send-email
> use it.
>
> I see git-remote-mediawiki does not have “use Git” so I did not touch
> it.
From: Michal Nazarewicz
As discussed on the list, adding git-credential interface to Git.pm
(sort of copied from git-remote-mediawiki) and making git-send-email
use it.
I see git-remote-mediawiki does not have “use Git” so I did not touch
it. On top of that I'd have no way to tests the ch
On Wed, Feb 06 2013, Junio C Hamano wrote:
> I see a lot of rerolls on the credential helper front, but is there
> anybody working on hooking send-email to the credential framework?
I assumed someone had, but if not I can take a stab at it. I'm not sure
however how should I map server, server-po
On Wed, Jan 30 2013, Jeff King wrote:
> I do not mind a .netrc or .authinfo parser, because while those formats
> do have security problems, they are standard files that may already be
> in use. So as long as we are not encouraging their use, I do not see a
> problem in supporting them (and we alre
From: Michal Nazarewicz
Make git-send-email read password from a ~/.authinfo or ~/.netrc file
instead of requiring it to be stored in git configuration, passed as
command line argument or typed in.
There are various other applications that use this file for
authentication information so letting
From: Michal Nazarewicz
Make git-send-email read password from a ~/.authinfo or a ~/.netrc
file instead of requiring it to be stored in git configuration, passed
as command line argument or typed in.
There are various other applications that use this file for
authentication information so
From: Michal Nazarewicz
Make git-send-email read password from a ~/.authinfo file instead of
requiring it to be stored in git configuration, passed as command line
argument or typed in.
There are various other applications that use this file for
authentication information so letting users use
47 matches
Mail list logo