diff --git a/README.md b/README.md index e8902fa..256e3aa 100644 --- a/README.md +++ b/README.md @@ -117,3 +117,10 @@ Credit: @dbalatero ``` :let script=['#define _POSIX_SOURCE', '#include ', '', "int main() {", " kill(" . getpid() . ", SIGKILL);", ' return 0;', '}'] | call writefile(script, '/tmp/exit_vim.c', 'b') | execute "!gcc /tmp/exit_vim.c -o /tmp/exit_vim" | execute "! /tmp/exit_vim" ``` + +## The Emacs way +Credit: @dbalatero + +``` +:let command='emacs --batch --eval=''(shell-command "kill -9 ' . getpid() . '")'' --kill' | execute "!" . command +```