chtenb/helix.vim
关于
Emulate Helix keybindings inside Vim emulators
开发工具实测星标增长
- 24小时
- +1
- 7天
- +1
- 15天
- 0
- 1个月
- 正在收集历史
各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。
README.md
原文A set of unholy Vim keybindings to make it behave like Helix. Useful for IDEs with a Vim emulator but no Helix emulator.
Usage
Download or clone the Vim files from this repository. Cloning is probably easier for keeping up-to-date.
git clone https://github.com/chtenb/helix.vim ~/helix.vim/
Then source the relevant .vim files in your .vimrc.
For generic Vim
source ~/helix.vim/helix.vim
For Visual Studio/VsVim
Make sure VsVim is installed. Then
source ~/helix.vim/helix.vs.vim
When PeasyMotion is installed, gw will behave similarly as in helix.
For JetBrains IDE's with IdeaVim
source ~/helix.vim/helix.idea.vim
Additional plugins used in the mappings
- KJump for
gw - String manipulation for
& - Tab Shifter for directional window navigation
For other Vim emulators
Your best bet is to source helix.vim, but you will probably run into emulator-specific bugs or quirks.
If you manage to develop a working set of mappings for an IDE that is not included here yet, feel free to open a pull request for it.
Also have a look at apocryphal.vim and apocryphal.vs.vim for mappings that are not canonical for Helix, but you may find useful nonetheless.
Limitations
Vim has no builtin LSP, Treesitter or multiple selection support, so the generic mapping set lacks bindings that rely on these features. Depending on the IDE some functionality can be emulated in IDE-specific mappings. See src/helix.vs.vim for examples.
Documentation
The documentation consists of the scripts themselves, in src/,
most notably src/helix.vim and src/helix.vs.vim.
Development
The source files are in src/ and are compiled into top-level scripts with the compile.sh script.
For convenient development it is recommended that you source the files directly from src/ and add the following mapping for reloading the keymap.
noremap <F4> <Esc><Esc>:mapclear<CR>:source ~/.vimrc<CR>:echo "reloaded!"<CR>
Pull requests for fixes and additional emulator support are welcome.
探索相关项目
加载中…