Open xgretsch opened 9 years ago
See also #1188
I'm part way to solving this. The trick is reboot the Mac into its recovery console, then type the magic words "csrutil disable" as in this post. This then allows me to copy ssh-askpass into /usr/X11R6/bin.
I've still got the ssh key problem described in #1188, got to investigate that one now.
It seems that brackets-git is looking for ssh-askpass which is not available in OSX. However you can install it from https://github.com/theseal/ssh-askpass and following the instructions.
Unfortunately, even with ssh-askpass, brackets-git is still unable to use the key.
This is not a Brackets problem nor a brackets-git problem, nor is it even a git problem or a github problem. It is an ssh problem and, more specifically, a problem with Mac users using ssh, on specific versions of macOS, to communicate with a git repository through this extension.
As @denics stated, the password dialog no longer pops up because the program that used to be available to pop up the password dialog box, ssh-askpass.exe
, was removed from some recent version of macOS. At least, I assume that is what happened because the password dialog used to pop up for me in this extension at some time in the past.
The easiest workaround -- clunky as it may be -- is to open a terminal window and navigate to the project directory and type git push <repository> <branch>
, then type in your password in the terminal. Typically the command is git push origin master
if you use standard naming conventions for the remote SSH address name and the main branch.
@xgretsch I assume getting a copy of the file from https://github.com/theseal/ssh-askpass and reconfiguring the System Integrity Protection so that you can throw ssh-askpass.exe
into /usr/X11R6/bin
is working. The only problem I can see is a future OS update might overwrite the changes.
Unfortunately, I haven't figured out a better way to make this work. I've been trying to figure out how to configure the path environmental variable SSH_ASKPASS
to stop pointing to /usr/X11R6/bin
so I can use my local version of ssh-askpass.exe
but I have not gotten it to work yet.
I guess the point of this post is to say that, first off, this is not a bug with this extension and there is no code fix that will help. The best we could do is pull together the information we have and create some documentation on how to fix the problem and post it to the repository, maybe add it to the READ_ME.md
. If I ever figure it out an elegant solution, I would be glad to update the documentation. Until then, I'm just dropping back into the terminal window to do my git push
command.
@xgretsch, I tried your method out and it definitely does launch the password dialog. My problem is the dialog has no text box in it to enter the password :). So, I still can't figure out how to use the https://github.com/theseal/ssh-askpass solution. Did you ever get it to work for you?
No, I never did get it to work. Like @lkcampbell, I just dropped back to using the terminal window. I haven't actually been doing any work on XDK for the last year or so, but when I next get back to looking at my XDK app, I'll get things reinstalled and let you know if I have any success.
By the way, I agree that this is an Apple problem and not a brackets or brackets-git problem. But one of the joys of being a small developer (or even a small team in a large company like Intel) is that you don't really have any leverage over OS providers like Apple: if they break stuff, the best we can all do for our users is to work around it, because they're not going to listen when we complain about what they see as obscure areas of their code.
@xgretsch agreed. That's why I think this discussion is helpful as documentation. Maybe dropping into the terminal window is the best solution for now. It is clunky but hey, at least it works :).
FYI, you can hit the terminal window button on the extension and it will navigate to the directory automatically. One more step that helps a bit, so thanks @zaggino for having it as part of the UI.
@I had this issue when pushing from within Sublime Text to a remote site that was prompting for my password. The workaround of pushing from the command line worked.
But my real fix was to append ~/.ssh/id_rsa.pub from my local machine to ~/.ssh.authorized_keys on the remote system, eliminating the password prompt both from the command line and from within Sublime. (Both the username and password on the remote system are different from the username and password on the local system: that's okay.)
I upgraded to OS X El Capitan
I then simply did a push to remote, in a way that has worked previously.
Note the following:
I used to have an ssh-askpass in /usr/libexec. This seems to have vanished, presumably as a result of the El Capitan upgrade.
I am no longer permitted - even with sudo - to add anything to /usr.
Adding ssh-askpass somewhere else in my path doesn't cure this problem.
Brackets 1.4.0-0 (mac), Git 2.3.8 (Apple Git-58) & Brackets-Git 0.14.28
Pushing to remote failed