unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* git push via VC failure
@ 2018-07-30 12:52 Stephen Berman
  2018-07-30 17:09 ` Noam Postavsky
  0 siblings, 1 reply; 3+ messages in thread
From: Stephen Berman @ 2018-07-30 12:52 UTC (permalink / raw)
  To: emacs-devel

[-- Attachment #1: Type: text/plain, Size: 224 bytes --]

I've recently pushed a few commits to emacs-26 and master, and in each
case, tying 'P' in the *vc-dir* buffer failed; but typing 'git push' in
bash succeeded.  Here is the output displayed in the vc-git compilation
buffer:


[-- Attachment #2: vc-git compilation output --]
[-- Type: text/plain, Size: 630 bytes --]

Running "git push"...
ssh_askpass: exec(/usr/libexec/ssh-askpass): No such file or directory

ssh_askpass: exec(/usr/libexec/ssh-askpass): No such file or directory

Permission denied, please try again.

ssh_askpass: exec(/usr/libexec/ssh-askpass): No such file or directory

Permission denied, please try again.

ssh_askpass: exec(/usr/libexec/ssh-askpass): No such file or directory

Received disconnect from 208.118.235.201 port 22:2: Too many authentication failures for srb

Authentication failed.

fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

[-- Attachment #3: Type: text/plain, Size: 499 bytes --]


I've gotten this on two different GNU/Linux systems, one does not have
ssh-askpass installed, the other does but it is in /usr/libexec/openssh;
so does VC really require ssh-askpass directly in /usr/libexec?  If so,
I guess I could symlink it there, but this seems suboptimal.  Again, in
both systems 'git push' from the shell succeeded, so git itself seems to
be configured correctly and ssh-askpass doesn't seem to be required.  Or
is there some other reason for the failure in VC?

Steve Berman

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: git push via VC failure
  2018-07-30 12:52 git push via VC failure Stephen Berman
@ 2018-07-30 17:09 ` Noam Postavsky
  2018-07-30 17:20   ` Stephen Berman
  0 siblings, 1 reply; 3+ messages in thread
From: Noam Postavsky @ 2018-07-30 17:09 UTC (permalink / raw)
  To: Stephen Berman; +Cc: Emacs developers

On 30 July 2018 at 08:52, Stephen Berman <stephen.berman@gmx.net> wrote:

> I've gotten this on two different GNU/Linux systems, one does not have
> ssh-askpass installed, the other does but it is in /usr/libexec/openssh;
> so does VC really require ssh-askpass directly in /usr/libexec?  If so,
> I guess I could symlink it there, but this seems suboptimal.  Again, in
> both systems 'git push' from the shell succeeded, so git itself seems to
> be configured correctly and ssh-askpass doesn't seem to be required.  Or
> is there some other reason for the failure in VC?

Are you using ssh-agent, and are SSH_AGENT_PID and SSH_AUTH_SOCK set
in your shell but not in Emacs?

I have written the ssh-agency package which tries to find the correct
values for those environment variables automatically. Originally it
was written for magit on w32 systems, but it turns out to be useful on
GNU systems as well. And it should be usable for vc-git, it's just a a
matter of arranging to have `ssh-agency-ensure' called before 'git
push' is run.

Or if you expect to get a password prompt every time, then I think
it's just that Emacs is not using a pty when running 'git push', which
causes git (or ssh?) to use ssh-askpass instead.



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: git push via VC failure
  2018-07-30 17:09 ` Noam Postavsky
@ 2018-07-30 17:20   ` Stephen Berman
  0 siblings, 0 replies; 3+ messages in thread
From: Stephen Berman @ 2018-07-30 17:20 UTC (permalink / raw)
  To: Noam Postavsky; +Cc: Emacs developers

On Mon, 30 Jul 2018 13:09:41 -0400 Noam Postavsky <npostavs@gmail.com> wrote:

> On 30 July 2018 at 08:52, Stephen Berman <stephen.berman@gmx.net> wrote:
>
>> I've gotten this on two different GNU/Linux systems, one does not have
>> ssh-askpass installed, the other does but it is in /usr/libexec/openssh;
>> so does VC really require ssh-askpass directly in /usr/libexec?  If so,
>> I guess I could symlink it there, but this seems suboptimal.  Again, in
>> both systems 'git push' from the shell succeeded, so git itself seems to
>> be configured correctly and ssh-askpass doesn't seem to be required.  Or
>> is there some other reason for the failure in VC?
>
> Are you using ssh-agent, and are SSH_AGENT_PID and SSH_AUTH_SOCK set
> in your shell but not in Emacs?

Ah, that must be it.  Thanks for calling it to my attention.

> I have written the ssh-agency package which tries to find the correct
> values for those environment variables automatically. Originally it
> was written for magit on w32 systems, but it turns out to be useful on
> GNU systems as well. And it should be usable for vc-git, it's just a a
> matter of arranging to have `ssh-agency-ensure' called before 'git
> push' is run.

Thanks for the pointer, I'll give it a try.

Steve Berman



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-07-30 17:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-07-30 12:52 git push via VC failure Stephen Berman
2018-07-30 17:09 ` Noam Postavsky
2018-07-30 17:20   ` Stephen Berman

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).