841 |
See also `tramp-yesno-prompt-regexp'." |
See also `tramp-yesno-prompt-regexp'." |
842 |
:group 'tramp |
:group 'tramp |
843 |
:type 'regexp) |
:type 'regexp) |
844 |
|
|
845 |
|
(defcustom tramp-terminal-prompt-regexp |
846 |
|
(concat "\\(" |
847 |
|
"TERM = (.*)" |
848 |
|
"\\|" |
849 |
|
"Terminal type\\? \\[.*\\]" |
850 |
|
"\\)\\s-*") |
851 |
|
"Regular expression matching all terminal setting prompts. |
852 |
|
The regexp should match at end of buffer. |
853 |
|
The answer will be provided by `tramp-action-terminal', which see." |
854 |
|
:group 'tramp |
855 |
|
:type 'regexp) |
856 |
|
|
857 |
(defcustom tramp-temp-name-prefix "tramp." |
(defcustom tramp-temp-name-prefix "tramp." |
858 |
"*Prefix to use for temporary files. |
"*Prefix to use for temporary files. |
1211 |
(tramp-shell-prompt-pattern tramp-action-succeed) |
(tramp-shell-prompt-pattern tramp-action-succeed) |
1212 |
(tramp-wrong-passwd-regexp tramp-action-permission-denied) |
(tramp-wrong-passwd-regexp tramp-action-permission-denied) |
1213 |
(tramp-yesno-prompt-regexp tramp-action-yesno) |
(tramp-yesno-prompt-regexp tramp-action-yesno) |
1214 |
(tramp-yn-prompt-regexp tramp-action-yn)) |
(tramp-yn-prompt-regexp tramp-action-yn) |
1215 |
|
(tramp-terminal-prompt-regexp tramp-action-terminal)) |
1216 |
"List of pattern/action pairs. |
"List of pattern/action pairs. |
1217 |
Whenever a pattern matches, the corresponding action is performed. |
Whenever a pattern matches, the corresponding action is performed. |
1218 |
Each item looks like (PATTERN ACTION). |
Each item looks like (PATTERN ACTION). |
4395 |
(throw 'tramp-action 'permission-denied)) |
(throw 'tramp-action 'permission-denied)) |
4396 |
(process-send-string p (concat "y" tramp-rsh-end-of-line)))) |
(process-send-string p (concat "y" tramp-rsh-end-of-line)))) |
4397 |
|
|
4398 |
|
(defun tramp-action-terminal (p multi-method method user host) |
4399 |
|
"Tell the remote host which terminal type to use. |
4400 |
|
The terminal type can be configured with `tramp-terminal-type'." |
4401 |
|
(tramp-message 9 "Setting `%s' as terminal type." |
4402 |
|
tramp-terminal-type) |
4403 |
|
(erase-buffer) |
4404 |
|
(process-send-string nil (concat tramp-terminal-type |
4405 |
|
tramp-rsh-end-of-line))) |
4406 |
|
|
4407 |
;; The following functions are specifically for multi connections. |
;; The following functions are specifically for multi connections. |
4408 |
|
|
4409 |
(defun tramp-multi-action-login (p method user host) |
(defun tramp-multi-action-login (p method user host) |