Domanda

How do I activate vim mode in Light Table 0.6.0. The docs say in the editor mode just type "vim" and it will auto complete, but now it doesn't? What do I add to my user behaviours?

{:+ {
 ;; The app tag is kind of like global scope. You assign behaviors that affect
 ;; all of Light Table here
 :app [(:lt.objs.style/set-skin "dark")]

 ;; The editor tag is applied to all editors
 :editor [:lt.objs.editor/no-wrap
          (:lt.objs.style/set-theme "default")]

 ;; Here we can add behaviors to just clojure editors
 :editor.clojure [(:lt.objs.langs.clj/print-length 1000)]}

 ;; You can use the subtract key to remove behavior that may get added by
 ;; another diff
 :- {:app []}}
È stato utile?

Soluzione

Had the same issue, from 0.6.0 changelog :

CHANGE: Emacs and Vim are now both plugins to be downloaded via the plugin manager

Download it, restart, and now it autocompletes when you type vim.

Altri suggerimenti

For default setting:

:editor [:lt.objs.editor/no-wrap
         (:lt.objs.style/set-theme "default")
         :lt.plugins.vim/activate-vim]

To customize it:

:editor [:lt.objs.editor/no-wrap
         (:lt.objs.style/set-theme "default")
         :lt.plugins.vim/activate-vim
         (:lt.plugins.vim/map-keys {"K" "{",
                                    "J" "}",
                                    "L" "$",
                                    "H" "^",
                                    "-" "$",
                                    "0" "^",
                                    "<BS>" "<PageUp>",
                                    "<Space>" "<PageDown>",
                                    "jj" "jj",
                                    "j" "gj",
                                    "k" "gk"})]

For all Vim mode keybindings see: https://github.com/marijnh/CodeMirror/blob/master/keymap/vim.js

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top