David Abrahams <[email protected]> writes: > Is this fix being integrated? > > Rüdiger Sonderfeld wrote: >> >> Hi, >> I just wrote a quick fix for it. That asks for the password. It needs >> some testing and magit-password should check if the Enter thing is >> really the second line after the "$ git" line. >> >> If you don't want to apply this highly experimental patch and find >> yourself in a situation where magit "hangs" because a process is >> running. Switch to the process buffer ($) and kill it (C-x k) and >> confirm with yes. This should help. >> >> Regards, >> Rüdiger <[email protected]> >> >> P.S. magit is really great. I love using it! >> >> Changes in HEAD >> Modified magit.el >> diff --git a/magit.el b/magit.el >> index bfbfe9b..7c694f5 100644 >> --- a/magit.el >> +++ b/magit.el >> @@ -1074,10 +1074,20 @@ Many Magit faces inherit from this one by >> default." >> (magit-set-mode-line-process nil) >> (magit-refresh-buffer magit-process-client-buffer))) >> >> +(defun magit-password (proc string) >> + "Checks if git/ssh asks for a password and ask the user for it." >> + (when (string-match "^Enter passphrase for key '\\\(.*\\\)': $" >> string) >> + (process-send-string proc >> + (concat (read-passwd >> + (format "Password for '%s': >> " (match-string 1 string)) >> + nil) "\n")))) >> + >> (defun magit-process-filter (proc string) >> (save-current-buffer >> (set-buffer (process-buffer proc)) >> (let ((inhibit-read-only t)) >> + (magit-password proc string) >> (goto-char (process-mark proc)) >> ;; Find last ^M in string. If one was found, ignore everything >> ;; before it and delete the current line. >> >> > > -- > Dave Abrahams Meet me at BoostCon: http://www.boostcon.com > BoostPro Computing > http://www.boostpro.com > >
This would be great for me; however, I am a writer (for whom version control is a god-send) and not a programmer, so I do not know how to patch my version of magit with this fix. Suggestions are welcome. Cheers. Ross -- Ross A. Laird, PhD www.rosslaird.com
