I'm administrating an Arch Linux server.
How can I securely add emacs to my
/etc/sudoers editor variable? Currently I have "emacs" but that allows
M-x shell. Basically, I want something like
rvim, but for emacs.
You probably can't do that.
Emacs is a Lisp Interpreter that runs an editor (which is written in emacs lisp), so every time you use emacs, you have access to the the lisp interpreter itself.
That interpreter can do all kinds of things: create/remove files or directories, change access rights etc... Basically, once you're inside emacs, you do not need to have access to a shell to do considerable damage - emacs itself is powerful enough.
Your best bet is probably to find a small emacs clone (for example here: http://www.emacswiki.org/emacs/EmacsImplementations ) that supports restricted editing.