4 ms·
You might like using the emacs server. (require 'server) (server-start) Then some shell aliases for instantaneous emacs from the shell: alias e="emacsc
by Myrmornis 14y ago
You might like using the emacs server.
(require 'server)
(server-start)
Then some shell aliases for instantaneous emacs from the shell:
alias e="emacsclient --no-wait"
Now
$ e myfile.c
in the shell will open the file instantaneously in the running emacs and the OS will switch window focus to emacs.
I use this a lot; magit-status on the current repo:
$ cat ~/bin/egit
emacsclient --no-wait \
--eval "(magit-status \"$PWD\")" \
--eval "(progn (select-frame-set-input-focus (selected-frame)) (delete-other-windows))"
- naner 14y agoYes, I've used it before. It isn't really necessary for my uses. Also it's easier to sudo zile than go through Tramp for editing system files.
- Myrmornis 14y agoAgree about tramp not being the solution. How is zile an improvement over emacs -nw -q ?
- naner 14y agoFewer characters? :) I dunno. I've done that in the past (actually using a separate init), too. Zile just seems simpler and it works fine for me. There's a billion ways to do things, it is hard to justify idiosyncrasies. I think what started it was that I drastically simplified my emacs init file (used to be several files, very smart and thought-out but massive and filled with rarely-used stuff) and I found myself always popping into nano for quick edits to system files. Well this quickly got annoying as there were conflicting key bindings with emacs and my muscle-memory was causing frequent errors. So I googled an emacs-flavored nano and settled on the first one I tried. Then I aliased nano to 'echo "USE ZILE"' until that became second nature, too.