Skip to content

Instantly share code, notes, and snippets.

@yohm
Created January 14, 2015 03:22
Show Gist options
  • Save yohm/9a5f47f2e62d4aa485ea to your computer and use it in GitHub Desktop.
Save yohm/9a5f47f2e62d4aa485ea to your computer and use it in GitHub Desktop.
My private.xml of Karabiner
<?xml version="1.0"?>
<root>
<appdef>
<appname>iTERM2</appname>
<equal>com.googlecode.iterm2</equal>
</appdef>
<appdef>
<appname>MACVIM</appname>
<equal>org.vim.MacVim</equal>
</appdef>
<list>
<item>
<name>Leave Insert Mode with EISUU (vim keybind apps)</name>
<identifier>private.vim_keybind_apps_esc_with_eisuu</identifier>
<only>iTERM2,TERMINAL,MACVIM</only>
<autogen>--KeyToKey-- KeyCode::ESCAPE, KeyCode::ESCAPE, KeyCode::JIS_EISUU</autogen>
<autogen>--KeyToKey-- KeyCode::BRACKET_LEFT, VK_CONTROL, KeyCode::BRACKET_LEFT, VK_CONTROL, KeyCode::JIS_EISUU</autogen>
</item>
<item>
<name>Vim in Preview</name>
<identifier>private.app_preview_vimium_in_preview</identifier>
<only>PREVIEW</only>
<autogen>__KeyToKey__ KeyCode::J, ModifierFlag::NONE, KeyCode::CURSOR_DOWN</autogen>
<autogen>__KeyToKey__ KeyCode::K, ModifierFlag::NONE, KeyCode::CURSOR_UP</autogen>
<autogen>__KeyToKey__ KeyCode::H, ModifierFlag::NONE, KeyCode::CURSOR_LEFT</autogen>
<autogen>__KeyToKey__ KeyCode::L, ModifierFlag::NONE, KeyCode::CURSOR_RIGHT</autogen>
<autogen>__KeyToKey__ KeyCode::B, ModifierFlag::CONTROL_L, KeyCode::PAGEUP</autogen>
<autogen>__KeyToKey__ KeyCode::B, ModifierFlag::CONTROL_R, KeyCode::PAGEUP</autogen>
<autogen>__KeyToKey__ KeyCode::F, ModifierFlag::CONTROL_L, KeyCode::PAGEDOWN</autogen>
<autogen>__KeyToKey__ KeyCode::F, ModifierFlag::CONTROL_R, KeyCode::PAGEDOWN</autogen>
</item>
</list>
</root>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment