all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#22329: 24.3; Emacs Tramp feature suggestion: adding sg as a default connection method
@ 2016-01-08  7:29 Peng Bai
  2016-01-15 10:19 ` Michael Albinus
  0 siblings, 1 reply; 2+ messages in thread
From: Peng Bai @ 2016-01-08  7:29 UTC (permalink / raw)
  To: 22329


Following up a question on Stack Overflow
(http://stackoverflow.com/questions/34643837/in-emacs-how-do-i-use-tramp-ssh-to-edit-as-a-different-group-id):

I suggest adding "sg" as a default connection method. My specific use
case is that I have an account on a server, and that user belongs to
multiple groups (main group "group_A", secondary group "group_B") for
administrative reasons. SELinux Access Control is used so even if a
directory is owned by me, but if my main group ID is not right, I will
not be able to create files. In an interactive session, I would do
"chgrp group_B" to switch my main group, and a new shell session will be
created. If remotely launching a program, I would do "ssh foo.com 'sg
group_B /path/to/executable'".

Currently I add the following to my initialization script:

(eval-after-load 'tramp
  '(add-to-list
    'tramp-methods
    '("sg"
      (tramp-login-program "sg")
      (tramp-login-args (("-") ("%u")))
      (tramp-remote-shell "/bin/sh")
      (tramp-remote-shell-args ("-c")))))

Thank you!

Best regards,

Peng






^ permalink raw reply	[flat|nested] 2+ messages in thread

* bug#22329: 24.3; Emacs Tramp feature suggestion: adding sg as a default connection method
  2016-01-08  7:29 bug#22329: 24.3; Emacs Tramp feature suggestion: adding sg as a default connection method Peng Bai
@ 2016-01-15 10:19 ` Michael Albinus
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Albinus @ 2016-01-15 10:19 UTC (permalink / raw)
  To: Peng Bai; +Cc: 22329-done

Version: 25.2

Peng Bai <baipeng@sina.com> writes:

> I suggest adding "sg" as a default connection method.

I've added this to Tramp. Will be available with Tramp 2.3.0 and Emacs 25.2.

> Best regards,
>
> Peng

Best regards, Michael.





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-01-15 10:19 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-01-08  7:29 bug#22329: 24.3; Emacs Tramp feature suggestion: adding sg as a default connection method Peng Bai
2016-01-15 10:19 ` Michael Albinus

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.