diff options
| author | Michael Albinus | 2006-12-17 12:58:04 +0000 |
|---|---|---|
| committer | Michael Albinus | 2006-12-17 12:58:04 +0000 |
| commit | 210a7c2c92df94a193ae3143a4c39ee65923dd5f (patch) | |
| tree | 195a106279b600304563cc0ad7f8c65ddec34941 /lisp | |
| parent | f6e22881e2e567fea51226a35d4e195fcad0381e (diff) | |
| download | emacs-210a7c2c92df94a193ae3143a4c39ee65923dd5f.tar.gz emacs-210a7c2c92df94a193ae3143a4c39ee65923dd5f.zip | |
* net/tramp.el (tramp-default-method): Before setting to "pscp",
check whether package password.el is loaded, or Pageant is running.
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/ChangeLog | 5 | ||||
| -rw-r--r-- | lisp/net/tramp.el | 31 |
2 files changed, 32 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 30afd64ca65..a5de824ab06 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2006-12-17 Michael Albinus <michael.albinus@gmx.de> | ||
| 2 | |||
| 3 | * net/tramp.el (tramp-default-method): Before setting to "pscp", | ||
| 4 | check whether package password.el is loaded, or Pageant is running. | ||
| 5 | |||
| 1 | 2006-12-17 Ulf Jasper <ulf.jasper@web.de> | 6 | 2006-12-17 Ulf Jasper <ulf.jasper@web.de> |
| 2 | 7 | ||
| 3 | * calendar/icalendar.el (icalendar-version): Increase to "0.14". | 8 | * calendar/icalendar.el (icalendar-version): Increase to "0.14". |
diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index a45e1a22ad5..b2e4ec814fd 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el | |||
| @@ -684,10 +684,33 @@ various functions for details." | |||
| 684 | :type '(repeat (list string function string))) | 684 | :type '(repeat (list string function string))) |
| 685 | 685 | ||
| 686 | (defcustom tramp-default-method | 686 | (defcustom tramp-default-method |
| 687 | (if (and (fboundp 'executable-find) | 687 | (or |
| 688 | (executable-find "pscp")) | 688 | ;; An external copy method seems to be preferred, because it is |
| 689 | "pscp" | 689 | ;; much more performant for large files, and it hasn't too serious |
| 690 | "scp") | 690 | ;; delays for small files. But it must be ensured that there |
| 691 | ;; aren't permanent password queries. Either the copy method shall | ||
| 692 | ;; reuse other channels (ControlMaster of OpenSSH does it), a | ||
| 693 | ;; password agent like "ssh-agent" or "Pageant" shall run, or the | ||
| 694 | ;; optional password.el package shall be active for password caching. | ||
| 695 | (and (fboundp 'executable-find) | ||
| 696 | ;; Check whether PuTTY is installed. | ||
| 697 | (executable-find "pscp") | ||
| 698 | (if (or | ||
| 699 | ;; password.el is loaded. | ||
| 700 | (fboundp 'password-read) | ||
| 701 | ;; Pageant is running. | ||
| 702 | (and (fboundp 'w32-window-exists-p) | ||
| 703 | (funcall (symbol-function 'w32-window-exists-p) | ||
| 704 | "Pageant" "Pageant"))) | ||
| 705 | ;; We know that the password will not be retrieved again. | ||
| 706 | "pscp" | ||
| 707 | ;; When "pscp" exists, there is also "plink". | ||
| 708 | "plink")) | ||
| 709 | ;; Under UNIX, ControlMaster is activated. This does not work | ||
| 710 | ;; under Cygwin, but ssh-agent must be enabled then anyway due to | ||
| 711 | ;; the pseudo-tty problem of Cygwin's OpenSSH implementation. So | ||
| 712 | ;; it doesn't hurt to use "scp". | ||
| 713 | "scp") | ||
| 691 | "*Default method to use for transferring files. | 714 | "*Default method to use for transferring files. |
| 692 | See `tramp-methods' for possibilities. | 715 | See `tramp-methods' for possibilities. |
| 693 | Also see `tramp-default-method-alist'." | 716 | Also see `tramp-default-method-alist'." |