I’ve tried putting (setq term-setup-hook 'vip-mode) in my .emacs file but this only seems to load the vip module and I have to manually call vip-change-mode-to-vi and C-z doesn’t work as an alias for that method.
What am I doing wrong here?
p.s. Please spare me any religious sentiments.
You answered your own question, really: you need to call
vip-change-mode-to-vi. EMACS is just a lisp interpreter with some glossy side-effects; if you want to always be in vip vi mode, call the function.A couple things:
You should use
add-hook. What you’re using will remove any other hooks.(add-hook ‘term-setup-hook …)
Consider using a lambda expression to stick things together, as
(add-hook ‘term-setup-hook (lambda () (vip-mode)))
That means you have one closure that you can put all this stuff into