SVN GUI界面中的ssh_askpass错误

最近在mac下使用svnx会说一个错误:

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

这时候需要

sudo vi /usr/libexec/ssh-askpass

然后用vi编辑器输入

#! /bin/sh

#
# An SSH_ASKPASS command for MacOS X
#
# Author: Joseph Mocker, Sun Microsystems

#
# To use this script:
# setenv SSH_ASKPASS “macos-askpass”
# setenv DISPLAY “:0″
#

TITLE=${MACOS_ASKPASS_TITLE:-”SSH”}

DIALOG=”display dialog \”$@\” default answer \”\” with title \”$TITLE\”"
DIALOG=”$DIALOG with icon caution with hidden answer”

result=`osascript -e ‘tell application “Finder”‘ -e “activate” -e “$DIALOG” -e ‘end tell’`

if [ "$result" = "" ]; then
exit 1
else
echo “$result” | sed -e ’s/^text returned://’ -e ’s/, button returned:.*$//’
exit 0
fi

然后修复一下权限

sudo chmod +x /usr/libexec/ssh-askpass

One Response to “SVN GUI界面中的ssh_askpass错误”

  1. 银狐 Says:

    看的似懂非懂的~~谢谢分享~~

Leave a Reply