I use Evil mode inside Emacs to emulate vim-style editing. In the Xwindows based graphical user interface of Emacs on Ubuntu 16.04, Evil mode works perfectly.

When I launch emacs in terminal mode with emacs -nw foobar.cpp ,say I want to save a file with M-: w then I get the message in the message buffer saying M-: is not defined

However, the standard C-x C-s method of saving a file works in the terminal. How do I get the M-: behavior working in Emacs terminal mode as it does in graphical mode?

  • What's your terminal emulator? Chances are you don't get this in all terminal emulators and depending on the specific terminal emulator, you'll get different issues.
    – wasamasa
    Commented Jun 1, 2018 at 17:47
  • @wasamasa I use guake and terminator on Ubuntu 16.04, alongside the zshell. Commented Jun 2, 2018 at 5:22
  • @wasamasa It seems the problem happens when I am using Emacs from inside of a tmux session. When tmux is not on, then M-: works as intended. Commented Jun 2, 2018 at 5:34
  • 1
    That aside, M-: isn't a command defined by Evil. This would only be Evil-related if enabling Evil would trigger this and M-: worked fine otherwise...
    – wasamasa
    Commented Jun 2, 2018 at 23:14


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.