Commit 05570f00 authored by Michael Albinus's avatar Michael Albinus

Minor cleanup for Tramp "doas".

* doc/misc/tramp.texi (Inline methods): Add "doas" method.

* etc/NEWS: Add Tramp connection method "doas".

* lisp/net/tramp-sh.el (tramp-methods) <doas>:
Add `tramp-remote-shell-args'.
parent d66e8f72
......@@ -590,6 +590,12 @@ the host returned by the function @command{(system-name)}. See
Similar to @option{su} method, @option{sudo} uses @command{sudo}.
@command{sudo} must have sufficient rights to start a shell.
@item @option{doas}
@cindex method doas
@cindex doas method
This method is used on OpenBSD like the @command{sudo} command.
@item @option{sg}
@cindex method sg
@cindex sg method
......
......@@ -67,9 +67,13 @@ for the ChangeLog file, if none already exists. Customize
** Tramp
+++
*** New connection method "sg", which allows to edit files under
different group ID.
+++
*** New connection method "doas" for OpenBSD hosts.
* New Modes and Packages in Emacs 25.2
......
......@@ -312,6 +312,7 @@ The string is used in `tramp-methods'.")
(tramp-login-program "doas")
(tramp-login-args (("-u" "%u") ("-s")))
(tramp-remote-shell "/bin/sh")
(tramp-remote-shell-args ("-c"))
(tramp-connection-timeout 10)))
;;;###tramp-autoload
(add-to-list 'tramp-methods
......@@ -415,7 +416,7 @@ The string is used in `tramp-methods'.")
;;;###tramp-autoload
(add-to-list 'tramp-default-user-alist
`(,(concat "\\`" (regexp-opt '("su" "sudo" "ksu" "doas")) "\\'")
`(,(concat "\\`" (regexp-opt '("su" "sudo" "doas" "ksu")) "\\'")
nil "root"))
;; Do not add "ssh" based methods, otherwise ~/.ssh/config would be ignored.
;; Do not add "plink" based methods, they ask interactively for the user.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment