Skip to content

Instantly share code, notes, and snippets.

@emilk
Created May 10, 2020 15:21
Show Gist options
  • Select an option

  • Save emilk/aa673063e856ca1b94e0d4a91f26f558 to your computer and use it in GitHub Desktop.

Select an option

Save emilk/aa673063e856ca1b94e0d4a91f26f558 to your computer and use it in GitHub Desktop.

Revisions

  1. emilk created this gist May 10, 2020.
    16 changes: 16 additions & 0 deletions DefaultKeyBinding.dict
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,16 @@
    {
    /* Remap Home / End keys to be correct */
    "\UF729" = "moveToBeginningOfLine:"; /* Home */
    "\UF72B" = "moveToEndOfLine:"; /* End */
    "$\UF729" = "moveToBeginningOfLineAndModifySelection:"; /* Shift + Home */
    "$\UF72B" = "moveToEndOfLineAndModifySelection:"; /* Shift + End */
    "^\UF729" = "moveToBeginningOfDocument:"; /* Ctrl + Home */
    "^\UF72B" = "moveToEndOfDocument:"; /* Ctrl + End */
    "$^\UF729" = "moveToBeginningOfDocumentAndModifySelection:"; /* Shift + Ctrl + Home */
    "$^\UF72B" = "moveToEndOfDocumentAndModifySelection:"; /* Shift + Ctrl + End */

    /* workaround: https://superuser.com/questions/1418419/macos-making-bell-sound-on-moving-line-down-in-visual-studio-code */
    "^@\UF701" = "noop";
    "^@\UF702" = "noop";
    "^@\UF703" = "noop";
    }