commit ddf94347baab47f4a7395043f4e2f654d109a879 Author: moparisthebest Date: Wed Sep 27 14:37:16 2023 -0400 Initial commit diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..72e8ffc --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +* diff --git a/README.md b/README.md new file mode 100644 index 0000000..3ea8e01 --- /dev/null +++ b/README.md @@ -0,0 +1,11 @@ +moparisthebest's helix config +----------------------------- + +I use [Unix Programmer's Dvorak](https://github.com/moparisthebest/rusty-keys) for a keyboard layout, so when I started to learn helix, +I wanted to keep all the keys in the same position, but mapped to Dvorak. There isn't even a default layout file for helix, so with +some awful bash and a tiny bit of manual editing I managed to: + +1. extract default keymap from helix source code (config.orig.toml) +2. automatically convert it to dvorak (config.dvorak.toml) + +I'll also keep my personal config.toml here, where I may make more tweaks. diff --git a/config.dvorak.toml b/config.dvorak.toml new file mode 100644 index 0000000..f5d00e2 --- /dev/null +++ b/config.dvorak.toml @@ -0,0 +1,406 @@ + +[keys.normal] +"d" = "move_char_left" # "h" | "left" +"left" = "move_char_left" # "h" | "left" +"h" = "move_visual_line_down" # "j" | "down" +"down" = "move_visual_line_down" # "j" | "down" +"t" = "move_visual_line_up" # "k" | "up" +"up" = "move_visual_line_up" # "k" | "up" +"n" = "move_char_right" # "l" | "right" +"right" = "move_char_right" # "l" | "right" +"y" = "find_till_char" # "t" +"u" = "find_next_char" # "f" +"Y" = "till_prev_char" # "T" +"U" = "find_prev_char" # "F" +"p" = "replace" # "r" +"P" = "replace_with_yanked" # "R" +"A-." = "repeat_last_motion" # "A-." +"~" = "switch_case" # "~" +"`" = "switch_to_lowercase" # "`" +"A-`" = "switch_to_uppercase" # "A-`" +"home" = "goto_line_start" # "home" +"end" = "goto_line_end" # "end" +"," = "move_next_word_start" # "w" +"x" = "move_prev_word_start" # "b" +"." = "move_next_word_end" # "e" +"<" = "move_next_long_word_start" # "W" +"X" = "move_prev_long_word_start" # "B" +">" = "move_next_long_word_end" # "E" +"k" = "select_mode" # "v" +"I" = "goto_line" # "G" + +"S" = "command_mode" # ":" +"c" = "insert_mode" # "i" +"C" = "insert_at_line_start" # "I" +"a" = "append_mode" # "a" +"A" = "insert_at_line_end" # "A" +"r" = "open_below" # "o" +"R" = "open_above" # "O" +"e" = "delete_selection" # "d" +"A-d" = "delete_selection_noyank" # "A-d" +"j" = "change_selection" # "c" +"A-c" = "change_selection_noyank" # "A-c" +"J" = "copy_selection_on_next_line" # "C" +"A-C" = "copy_selection_on_prev_line" # "A-C" +"o" = "select_regex" # "s" +"A-s" = "split_selection_on_newline" # "A-s" +# error? "A-minus" = "merge_selections" # "A-minus" +"A-_" = "merge_consecutive_selections" # "A-_" +"O" = "split_selection" # "S" +"s" = "collapse_selection" # ";" +"A-;" = "flip_selections" # "A-;" +"A-o" = "expand_selection" # "A-o" | "A-up" +"A-up" = "expand_selection" # "A-o" | "A-up" +"A-i" = "shrink_selection" # "A-i" | "A-down" +"A-down" = "shrink_selection" # "A-i" | "A-down" +"A-p" = "select_prev_sibling" # "A-p" | "A-left" +"A-left" = "select_prev_sibling" # "A-p" | "A-left" +"A-n" = "select_next_sibling" # "A-n" | "A-right" +"A-right" = "select_next_sibling" # "A-n" | "A-right" +# error? "A-e" = "move_parent_node_end" # "A-e" +# error? "A-b" = "move_parent_node_start" # "A-b" +"%" = "select_all" # "%" +"q" = "extend_line_below" # "x" +"Q" = "extend_to_line_bounds" # "X" +"A-x" = "shrink_to_line_bounds" # "A-x" + +"z" = "search" # "/" +"Z" = "rsearch" # "?" +"b" = "search_next" # "n" +"B" = "search_prev" # "N" +"*" = "search_selection" # "*" +"g" = "undo" # "u" +"G" = "redo" # "U" +"A-u" = "earlier" # "A-u" +"A-U" = "later" # "A-U" +"f" = "yank" # "y" +"l" = "paste_after" # "p" +"L" = "paste_before" # "P" +"\"" = "record_macro" # "Q" +"'" = "replay_macro" # "q" +"V" = "indent" # ">" +"W" = "unindent" # "<" +"]" = "format_selections" # "=" +"H" = "join_selections" # "J" +"A-J" = "join_selections_space" # "A-J" +"T" = "keep_selections" # "K" +"A-K" = "remove_selections" # "A-K" +"w" = "keep_primary_selection" # "," +"A-," = "remove_primary_selection" # "A-," + +# "q" = "record_macro" # "q" +#"Q" = "replay_macro" # "Q" + +"&" = "align_selections" # "&" +"{" = "trim_selections" # "_" +"(" = "rotate_selections_backward" # "(" +")" = "rotate_selections_forward" # ")" +"A-(" = "rotate_selection_contents_backward" # "A-(" +"A-)" = "rotate_selection_contents_forward" # "A-)" +"A-:" = "ensure_selections_forward" # "A-:" +"esc" = "normal_mode" # "esc" +"C-b" = "page_up" # "C-b" | "pageup" +"pageup" = "page_up" # "C-b" | "pageup" +"C-f" = "page_down" # "C-f" | "pagedown" +"pagedown" = "page_down" # "C-f" | "pagedown" +"C-u" = "half_page_up" # "C-u" +"C-d" = "half_page_down" # "C-d" + +"C-c" = "toggle_comments" # "C-c" +"C-i" = "jump_forward" # "C-i" | "tab" // tab == +"tab" = "jump_forward" # "C-i" | "tab" // tab == +"C-o" = "jump_backward" # "C-o" +"C-s" = "save_selection" # "C-s" + +"_" = "select_register" # "\"" +"|" = "shell_pipe" # "|" +"A-|" = "shell_pipe_to" # "A-|" +"!" = "shell_insert_output" # "!" +"A-!" = "shell_append_output" # "A-!" +"$" = "shell_keep_pipe" # "$" +"C-z" = "suspend" # "C-z" +"C-a" = "increment" # "C-a" +"C-x" = "decrement" # "C-x" + +[keys.normal.i] # [keys.normal.g] +"i" = "goto_file_start" # "g" +"." = "goto_last_line" # "e" +"u" = "goto_file" # "f" +"d" = "goto_line_start" # "h" +"n" = "goto_line_end" # "l" +"o" = "goto_first_nonwhitespace" # "s" +"e" = "goto_definition" # "d" +"E" = "goto_declaration" # "D" +"f" = "goto_type_definition" # "y" +"p" = "goto_reference" # "r" +"c" = "goto_implementation" # "i" +"y" = "goto_window_top" # "t" +"j" = "goto_window_center" # "c" +"x" = "goto_window_bottom" # "b" +"a" = "goto_last_accessed_file" # "a" +"m" = "goto_last_modified_file" # "m" +"b" = "goto_next_buffer" # "n" +"l" = "goto_previous_buffer" # "p" +"t" = "move_line_up" # "k" +"h" = "move_line_down" # "j" +"v" = "goto_last_modification" # "." + +[keys.normal.m] # [keys.normal.m] +"m" = "match_brackets" # "m" +"o" = "surround_add" # "s" +"p" = "surround_replace" # "r" +"e" = "surround_delete" # "d" +"a" = "select_textobject_around" # "a" +"c" = "select_textobject_inner" # "i" + +[keys.normal."/"] # [keys.normal."["] +"e" = "goto_prev_diag" # "d" +"E" = "goto_first_diag" # "D" +"i" = "goto_prev_change" # "g" +"I" = "goto_first_change" # "G" +"u" = "goto_prev_function" # "f" +"y" = "goto_prev_class" # "t" +"a" = "goto_prev_parameter" # "a" +"j" = "goto_prev_comment" # "c" +"Y" = "goto_prev_test" # "T" +"l" = "goto_prev_paragraph" # "p" +"space" = "add_newline_above" # "space" + +[keys.normal."="] # [keys.normal."]"] +"e" = "goto_next_diag" # "d" +"E" = "goto_last_diag" # "D" +"i" = "goto_next_change" # "g" +"I" = "goto_last_change" # "G" +"u" = "goto_next_function" # "f" +"y" = "goto_next_class" # "t" +"a" = "goto_next_parameter" # "a" +"j" = "goto_next_comment" # "c" +"Y" = "goto_next_test" # "T" +"l" = "goto_next_paragraph" # "p" +"space" = "add_newline_below" # "space" + +[keys.normal.C-w] # [keys.normal.C-w] +"C-w" = "rotate_view" # "C-w" | "w" +"w" = "rotate_view" # "C-w" | "w" +"C-s" = "hsplit" # "C-s" | "s" +"s" = "hsplit" # "C-s" | "s" +"C-v" = "vsplit" # "C-v" | "v" +"v" = "vsplit" # "C-v" | "v" +"C-t" = "transpose_view" # "C-t" | "t" +"t" = "transpose_view" # "C-t" | "t" +"u" = "goto_file_hsplit" # "f" +"U" = "goto_file_vsplit" # "F" +"C-q" = "wclose" # "C-q" | "q" +"q" = "wclose" # "C-q" | "q" +"C-o" = "wonly" # "C-o" | "o" +"o" = "wonly" # "C-o" | "o" +"C-h" = "jump_view_left" # "C-h" | "h" | "left" +"h" = "jump_view_left" # "C-h" | "h" | "left" +"left" = "jump_view_left" # "C-h" | "h" | "left" +"C-j" = "jump_view_down" # "C-j" | "j" | "down" +"j" = "jump_view_down" # "C-j" | "j" | "down" +"down" = "jump_view_down" # "C-j" | "j" | "down" +"C-k" = "jump_view_up" # "C-k" | "k" | "up" +"k" = "jump_view_up" # "C-k" | "k" | "up" +"up" = "jump_view_up" # "C-k" | "k" | "up" +"C-l" = "jump_view_right" # "C-l" | "l" | "right" +"l" = "jump_view_right" # "C-l" | "l" | "right" +"right" = "jump_view_right" # "C-l" | "l" | "right" +"N" = "swap_view_right" # "L" +"T" = "swap_view_up" # "K" +"D" = "swap_view_left" # "H" +"H" = "swap_view_down" # "J" + +[keys.normal.C-w.b] # [keys.normal.C-w.n] +"C-s" = "hsplit_new" # "C-s" | "s" +"s" = "hsplit_new" # "C-s" | "s" +"C-v" = "vsplit_new" # "C-v" | "v" +"v" = "vsplit_new" # "C-v" | "v" + +[keys.normal.space] +"u" = "file_picker" # "f" +"U" = "file_picker_in_current_directory" # "F" +"x" = "buffer_picker" # "b" +"h" = "jumplist_picker" # "j" +"o" = "symbol_picker" # "s" +"O" = "workspace_symbol_picker" # "S" +"e" = "diagnostics_picker" # "d" +"E" = "workspace_diagnostics_picker" # "D" +"a" = "code_action" # "a" +"minus" = "last_picker" # "'" + +"f" = "yank_joined_to_clipboard" # "y" +"F" = "yank_main_selection_to_clipboard" # "Y" +"l" = "paste_clipboard_after" # "p" +"L" = "paste_clipboard_before" # "P" +"P" = "replace_selections_with_clipboard" # "R" +"z" = "global_search" # "/" +"t" = "hover" # "k" +"p" = "rename_symbol" # "r" +"d" = "select_references_to_symbol_under_cursor" # "h" +"Z" = "command_palette" # "?" + +[keys.normal.space.i] # [keys.normal.space.g] +"n" = "dap_launch" # "l" +"p" = "dap_restart" # "r" +"x" = "dap_toggle_breakpoint" # "b" +"j" = "dap_continue" # "c" +"d" = "dap_pause" # "h" +"c" = "dap_step_in" # "i" +"r" = "dap_step_out" # "o" +"b" = "dap_next" # "n" +"k" = "dap_variables" # "v" +"y" = "dap_terminate" # "t" +"C-c" = "dap_edit_condition" # "C-c" +"C-l" = "dap_edit_log" # "C-l" +"." = "dap_enable_exceptions" # "e" +">" = "dap_disable_exceptions" # "E" + +[keys.normal.space.i.o] # [keys.normal.space.g.s] +"y" = "dap_switch_thread" # "t" +"u" = "dap_switch_stack_frame" # "f" + +[keys.normal.space.","] # [keys.normal.space.w] +"C-w" = "rotate_view" # "C-w" | "w" +"w" = "rotate_view" # "C-w" | "w" +"C-s" = "hsplit" # "C-s" | "s" +"s" = "hsplit" # "C-s" | "s" +"C-v" = "vsplit" # "C-v" | "v" +"v" = "vsplit" # "C-v" | "v" +"C-t" = "transpose_view" # "C-t" | "t" +"t" = "transpose_view" # "C-t" | "t" +"u" = "goto_file_hsplit" # "f" +"U" = "goto_file_vsplit" # "F" +"C-q" = "wclose" # "C-q" | "q" +"q" = "wclose" # "C-q" | "q" +"C-o" = "wonly" # "C-o" | "o" +"o" = "wonly" # "C-o" | "o" +"C-h" = "jump_view_left" # "C-h" | "h" | "left" +"h" = "jump_view_left" # "C-h" | "h" | "left" +"left" = "jump_view_left" # "C-h" | "h" | "left" +"C-j" = "jump_view_down" # "C-j" | "j" | "down" +"j" = "jump_view_down" # "C-j" | "j" | "down" +"down" = "jump_view_down" # "C-j" | "j" | "down" +"C-k" = "jump_view_up" # "C-k" | "k" | "up" +"k" = "jump_view_up" # "C-k" | "k" | "up" +"up" = "jump_view_up" # "C-k" | "k" | "up" +"C-l" = "jump_view_right" # "C-l" | "l" | "right" +"l" = "jump_view_right" # "C-l" | "l" | "right" +"right" = "jump_view_right" # "C-l" | "l" | "right" +"D" = "swap_view_left" # "H" +"H" = "swap_view_down" # "J" +"T" = "swap_view_up" # "K" +"N" = "swap_view_right" # "L" + +[keys.normal.space.",".b] # [keys.normal.space.w.n] +"C-s" = "hsplit_new" # "C-s" | "s" +"s" = "hsplit_new" # "C-s" | "s" +"C-v" = "vsplit_new" # "C-v" | "v" +"v" = "vsplit_new" # "C-v" | "v" + +[keys.normal.";"] # [keys.normal.z] +";" = "align_view_center" # "z" | "c" +"c" = "align_view_center" # "z" | "c" +"y" = "align_view_top" # "t" +"x" = "align_view_bottom" # "b" +"m" = "align_view_middle" # "m" +"t" = "scroll_up" # "k" | "up" +"up" = "scroll_up" # "k" | "up" +"h" = "scroll_down" # "j" | "down" +"down" = "scroll_down" # "j" | "down" +"C-b" = "page_up" # "C-b" | "pageup" +"pageup" = "page_up" # "C-b" | "pageup" +"C-f" = "page_down" # "C-f" | "pagedown" +"pagedown" = "page_down" # "C-f" | "pagedown" +"C-u" = "half_page_up" # "C-u" | "backspace" +"backspace" = "half_page_up" # "C-u" | "backspace" +"C-d" = "half_page_down" # "C-d" | "space" +"space" = "half_page_down" # "C-d" | "space" +"z" = "search" # "/" +"Z" = "rsearch" # "?" +"b" = "search_next" # "n" +"B" = "search_prev" # "N" + +[keys.normal.":"] # [keys.normal.Z] +";" = "align_view_center" # "z" | "c" +"c" = "align_view_center" # "z" | "c" +"y" = "align_view_top" # "t" +"x" = "align_view_bottom" # "b" +"m" = "align_view_middle" # "m" +"t" = "scroll_up" # "k" | "up" +"up" = "scroll_up" # "k" | "up" +"h" = "scroll_down" # "j" | "down" +"down" = "scroll_down" # "j" | "down" +"C-b" = "page_up" # "C-b" | "pageup" +"pageup" = "page_up" # "C-b" | "pageup" +"C-f" = "page_down" # "C-f" | "pagedown" +"pagedown" = "page_down" # "C-f" | "pagedown" +"C-u" = "half_page_up" # "C-u" | "backspace" +"backspace" = "half_page_up" # "C-u" | "backspace" +"C-d" = "half_page_down" # "C-d" | "space" +"space" = "half_page_down" # "C-d" | "space" +"z" = "search" # "/" +"Z" = "rsearch" # "?" +"b" = "search_next" # "n" +"B" = "search_prev" # "N" + +[keys.select] +"d" = "extend_char_left" # "h" | "left" +"left" = "extend_char_left" # "h" | "left" +"h" = "extend_visual_line_down" # "j" | "down" +"down" = "extend_visual_line_down" # "j" | "down" +"t" = "extend_visual_line_up" # "k" | "up" +"up" = "extend_visual_line_up" # "k" | "up" +"n" = "extend_char_right" # "l" | "right" +"right" = "extend_char_right" # "l" | "right" +"," = "extend_next_word_start" # "w" +"x" = "extend_prev_word_start" # "b" +"." = "extend_next_word_end" # "e" +"<" = "extend_next_long_word_start" # "W" +"X" = "extend_prev_long_word_start" # "B" +">" = "extend_next_long_word_end" # "E" +# error? "A-e" = "extend_parent_node_end" # "A-e" +# error? "A-b" = "extend_parent_node_start" # "A-b" +"b" = "extend_search_next" # "n" +"B" = "extend_search_prev" # "N" +"y" = "extend_till_char" # "t" +"u" = "extend_next_char" # "f" +"Y" = "extend_till_prev_char" # "T" +"U" = "extend_prev_char" # "F" +"home" = "extend_to_line_start" # "home" +"end" = "extend_to_line_end" # "end" +"esc" = "exit_select_mode" # "esc" +"k" = "normal_mode" # "v" + +[keys.select.i] # [keys.select.g] +"t" = "extend_line_up" # "k" +"h" = "extend_line_down" # "j" + +[keys.insert] +"esc" = "normal_mode" # "esc" +"C-s" = "commit_undo_checkpoint" # "C-s" +"C-x" = "completion" # "C-x" +"C-r" = "insert_register" # "C-r" +"C-w" = "delete_word_backward" # "C-w" | "A-backspace" +"A-backspace" = "delete_word_backward" # "C-w" | "A-backspace" +"A-d" = "delete_word_forward" # "A-d" | "A-del" +"A-del" = "delete_word_forward" # "A-d" | "A-del" +"C-u" = "kill_to_line_start" # "C-u" +"C-k" = "kill_to_line_end" # "C-k" +"C-h" = "delete_char_backward" # "C-h" | "backspace" | "S-backspace" +"backspace" = "delete_char_backward" # "C-h" | "backspace" | "S-backspace" +"S-backspace" = "delete_char_backward" # "C-h" | "backspace" | "S-backspace" +"C-d" = "delete_char_forward" # "C-d" | "del" +"del" = "delete_char_forward" # "C-d" | "del" +"C-j" = "insert_newline" # "C-j" | "ret" +"ret" = "insert_newline" # "C-j" | "ret" +# error? "tab" = "smart_tab" # "tab" +"S-tab" = "insert_tab" # "S-tab" +"up" = "move_visual_line_up" # "up" +"down" = "move_visual_line_down" # "down" +"left" = "move_char_left" # "left" +"right" = "move_char_right" # "right" +"pageup" = "page_up" # "pageup" +"pagedown" = "page_down" # "pagedown" +"home" = "goto_line_start" # "home" +"end" = "goto_line_end_newline" # "end" diff --git a/config.orig.toml b/config.orig.toml new file mode 100644 index 0000000..04b7ac1 --- /dev/null +++ b/config.orig.toml @@ -0,0 +1,406 @@ + +[keys.normal] +"h" = "move_char_left" # "h" | "left" +"left" = "move_char_left" # "h" | "left" +"j" = "move_visual_line_down" # "j" | "down" +"down" = "move_visual_line_down" # "j" | "down" +"k" = "move_visual_line_up" # "k" | "up" +"up" = "move_visual_line_up" # "k" | "up" +"l" = "move_char_right" # "l" | "right" +"right" = "move_char_right" # "l" | "right" +"t" = "find_till_char" # "t" +"f" = "find_next_char" # "f" +"T" = "till_prev_char" # "T" +"F" = "find_prev_char" # "F" +"r" = "replace" # "r" +"R" = "replace_with_yanked" # "R" +"A-." = "repeat_last_motion" # "A-." +"~" = "switch_case" # "~" +"`" = "switch_to_lowercase" # "`" +"A-`" = "switch_to_uppercase" # "A-`" +"home" = "goto_line_start" # "home" +"end" = "goto_line_end" # "end" +"w" = "move_next_word_start" # "w" +"b" = "move_prev_word_start" # "b" +"e" = "move_next_word_end" # "e" +"W" = "move_next_long_word_start" # "W" +"B" = "move_prev_long_word_start" # "B" +"E" = "move_next_long_word_end" # "E" +"v" = "select_mode" # "v" +"G" = "goto_line" # "G" + +":" = "command_mode" # ":" +"i" = "insert_mode" # "i" +"I" = "insert_at_line_start" # "I" +"a" = "append_mode" # "a" +"A" = "insert_at_line_end" # "A" +"o" = "open_below" # "o" +"O" = "open_above" # "O" +"d" = "delete_selection" # "d" +"A-d" = "delete_selection_noyank" # "A-d" +"c" = "change_selection" # "c" +"A-c" = "change_selection_noyank" # "A-c" +"C" = "copy_selection_on_next_line" # "C" +"A-C" = "copy_selection_on_prev_line" # "A-C" +"s" = "select_regex" # "s" +"A-s" = "split_selection_on_newline" # "A-s" +# error? "A-minus" = "merge_selections" # "A-minus" +"A-_" = "merge_consecutive_selections" # "A-_" +"S" = "split_selection" # "S" +";" = "collapse_selection" # ";" +"A-;" = "flip_selections" # "A-;" +"A-o" = "expand_selection" # "A-o" | "A-up" +"A-up" = "expand_selection" # "A-o" | "A-up" +"A-i" = "shrink_selection" # "A-i" | "A-down" +"A-down" = "shrink_selection" # "A-i" | "A-down" +"A-p" = "select_prev_sibling" # "A-p" | "A-left" +"A-left" = "select_prev_sibling" # "A-p" | "A-left" +"A-n" = "select_next_sibling" # "A-n" | "A-right" +"A-right" = "select_next_sibling" # "A-n" | "A-right" +# error? "A-e" = "move_parent_node_end" # "A-e" +# error? "A-b" = "move_parent_node_start" # "A-b" +"%" = "select_all" # "%" +"x" = "extend_line_below" # "x" +"X" = "extend_to_line_bounds" # "X" +"A-x" = "shrink_to_line_bounds" # "A-x" + +"/" = "search" # "/" +"?" = "rsearch" # "?" +"n" = "search_next" # "n" +"N" = "search_prev" # "N" +"*" = "search_selection" # "*" +"u" = "undo" # "u" +"U" = "redo" # "U" +"A-u" = "earlier" # "A-u" +"A-U" = "later" # "A-U" +"y" = "yank" # "y" +"p" = "paste_after" # "p" +"P" = "paste_before" # "P" +"Q" = "record_macro" # "Q" +"q" = "replay_macro" # "q" +">" = "indent" # ">" +"<" = "unindent" # "<" +"=" = "format_selections" # "=" +"J" = "join_selections" # "J" +"A-J" = "join_selections_space" # "A-J" +"K" = "keep_selections" # "K" +"A-K" = "remove_selections" # "A-K" +"," = "keep_primary_selection" # "," +"A-," = "remove_primary_selection" # "A-," + +# "q" = "record_macro" # "q" +#"Q" = "replay_macro" # "Q" + +"&" = "align_selections" # "&" +"_" = "trim_selections" # "_" +"(" = "rotate_selections_backward" # "(" +")" = "rotate_selections_forward" # ")" +"A-(" = "rotate_selection_contents_backward" # "A-(" +"A-)" = "rotate_selection_contents_forward" # "A-)" +"A-:" = "ensure_selections_forward" # "A-:" +"esc" = "normal_mode" # "esc" +"C-b" = "page_up" # "C-b" | "pageup" +"pageup" = "page_up" # "C-b" | "pageup" +"C-f" = "page_down" # "C-f" | "pagedown" +"pagedown" = "page_down" # "C-f" | "pagedown" +"C-u" = "half_page_up" # "C-u" +"C-d" = "half_page_down" # "C-d" + +"C-c" = "toggle_comments" # "C-c" +"C-i" = "jump_forward" # "C-i" | "tab" // tab == +"tab" = "jump_forward" # "C-i" | "tab" // tab == +"C-o" = "jump_backward" # "C-o" +"C-s" = "save_selection" # "C-s" + +"\"" = "select_register" # "\"" +"|" = "shell_pipe" # "|" +"A-|" = "shell_pipe_to" # "A-|" +"!" = "shell_insert_output" # "!" +"A-!" = "shell_append_output" # "A-!" +"$" = "shell_keep_pipe" # "$" +"C-z" = "suspend" # "C-z" +"C-a" = "increment" # "C-a" +"C-x" = "decrement" # "C-x" + +[keys.normal.g] # [keys.normal.g] +"g" = "goto_file_start" # "g" +"e" = "goto_last_line" # "e" +"f" = "goto_file" # "f" +"h" = "goto_line_start" # "h" +"l" = "goto_line_end" # "l" +"s" = "goto_first_nonwhitespace" # "s" +"d" = "goto_definition" # "d" +"D" = "goto_declaration" # "D" +"y" = "goto_type_definition" # "y" +"r" = "goto_reference" # "r" +"i" = "goto_implementation" # "i" +"t" = "goto_window_top" # "t" +"c" = "goto_window_center" # "c" +"b" = "goto_window_bottom" # "b" +"a" = "goto_last_accessed_file" # "a" +"m" = "goto_last_modified_file" # "m" +"n" = "goto_next_buffer" # "n" +"p" = "goto_previous_buffer" # "p" +"k" = "move_line_up" # "k" +"j" = "move_line_down" # "j" +"." = "goto_last_modification" # "." + +[keys.normal.m] # [keys.normal.m] +"m" = "match_brackets" # "m" +"s" = "surround_add" # "s" +"r" = "surround_replace" # "r" +"d" = "surround_delete" # "d" +"a" = "select_textobject_around" # "a" +"i" = "select_textobject_inner" # "i" + +[keys.normal."["] # [keys.normal."["] +"d" = "goto_prev_diag" # "d" +"D" = "goto_first_diag" # "D" +"g" = "goto_prev_change" # "g" +"G" = "goto_first_change" # "G" +"f" = "goto_prev_function" # "f" +"t" = "goto_prev_class" # "t" +"a" = "goto_prev_parameter" # "a" +"c" = "goto_prev_comment" # "c" +"T" = "goto_prev_test" # "T" +"p" = "goto_prev_paragraph" # "p" +"space" = "add_newline_above" # "space" + +[keys.normal."]"] # [keys.normal."]"] +"d" = "goto_next_diag" # "d" +"D" = "goto_last_diag" # "D" +"g" = "goto_next_change" # "g" +"G" = "goto_last_change" # "G" +"f" = "goto_next_function" # "f" +"t" = "goto_next_class" # "t" +"a" = "goto_next_parameter" # "a" +"c" = "goto_next_comment" # "c" +"T" = "goto_next_test" # "T" +"p" = "goto_next_paragraph" # "p" +"space" = "add_newline_below" # "space" + +[keys.normal.C-w] # [keys.normal.C-w] +"C-w" = "rotate_view" # "C-w" | "w" +"w" = "rotate_view" # "C-w" | "w" +"C-s" = "hsplit" # "C-s" | "s" +"s" = "hsplit" # "C-s" | "s" +"C-v" = "vsplit" # "C-v" | "v" +"v" = "vsplit" # "C-v" | "v" +"C-t" = "transpose_view" # "C-t" | "t" +"t" = "transpose_view" # "C-t" | "t" +"f" = "goto_file_hsplit" # "f" +"F" = "goto_file_vsplit" # "F" +"C-q" = "wclose" # "C-q" | "q" +"q" = "wclose" # "C-q" | "q" +"C-o" = "wonly" # "C-o" | "o" +"o" = "wonly" # "C-o" | "o" +"C-h" = "jump_view_left" # "C-h" | "h" | "left" +"h" = "jump_view_left" # "C-h" | "h" | "left" +"left" = "jump_view_left" # "C-h" | "h" | "left" +"C-j" = "jump_view_down" # "C-j" | "j" | "down" +"j" = "jump_view_down" # "C-j" | "j" | "down" +"down" = "jump_view_down" # "C-j" | "j" | "down" +"C-k" = "jump_view_up" # "C-k" | "k" | "up" +"k" = "jump_view_up" # "C-k" | "k" | "up" +"up" = "jump_view_up" # "C-k" | "k" | "up" +"C-l" = "jump_view_right" # "C-l" | "l" | "right" +"l" = "jump_view_right" # "C-l" | "l" | "right" +"right" = "jump_view_right" # "C-l" | "l" | "right" +"L" = "swap_view_right" # "L" +"K" = "swap_view_up" # "K" +"H" = "swap_view_left" # "H" +"J" = "swap_view_down" # "J" + +[keys.normal.C-w.n] # [keys.normal.C-w.n] +"C-s" = "hsplit_new" # "C-s" | "s" +"s" = "hsplit_new" # "C-s" | "s" +"C-v" = "vsplit_new" # "C-v" | "v" +"v" = "vsplit_new" # "C-v" | "v" + +[keys.normal.space] +"f" = "file_picker" # "f" +"F" = "file_picker_in_current_directory" # "F" +"b" = "buffer_picker" # "b" +"j" = "jumplist_picker" # "j" +"s" = "symbol_picker" # "s" +"S" = "workspace_symbol_picker" # "S" +"d" = "diagnostics_picker" # "d" +"D" = "workspace_diagnostics_picker" # "D" +"a" = "code_action" # "a" +"'" = "last_picker" # "'" + +"y" = "yank_joined_to_clipboard" # "y" +"Y" = "yank_main_selection_to_clipboard" # "Y" +"p" = "paste_clipboard_after" # "p" +"P" = "paste_clipboard_before" # "P" +"R" = "replace_selections_with_clipboard" # "R" +"/" = "global_search" # "/" +"k" = "hover" # "k" +"r" = "rename_symbol" # "r" +"h" = "select_references_to_symbol_under_cursor" # "h" +"?" = "command_palette" # "?" + +[keys.normal.space.g] # [keys.normal.space.g] +"l" = "dap_launch" # "l" +"r" = "dap_restart" # "r" +"b" = "dap_toggle_breakpoint" # "b" +"c" = "dap_continue" # "c" +"h" = "dap_pause" # "h" +"i" = "dap_step_in" # "i" +"o" = "dap_step_out" # "o" +"n" = "dap_next" # "n" +"v" = "dap_variables" # "v" +"t" = "dap_terminate" # "t" +"C-c" = "dap_edit_condition" # "C-c" +"C-l" = "dap_edit_log" # "C-l" +"e" = "dap_enable_exceptions" # "e" +"E" = "dap_disable_exceptions" # "E" + +[keys.normal.space.g.s] # [keys.normal.space.g.s] +"t" = "dap_switch_thread" # "t" +"f" = "dap_switch_stack_frame" # "f" + +[keys.normal.space.w] # [keys.normal.space.w] +"C-w" = "rotate_view" # "C-w" | "w" +"w" = "rotate_view" # "C-w" | "w" +"C-s" = "hsplit" # "C-s" | "s" +"s" = "hsplit" # "C-s" | "s" +"C-v" = "vsplit" # "C-v" | "v" +"v" = "vsplit" # "C-v" | "v" +"C-t" = "transpose_view" # "C-t" | "t" +"t" = "transpose_view" # "C-t" | "t" +"f" = "goto_file_hsplit" # "f" +"F" = "goto_file_vsplit" # "F" +"C-q" = "wclose" # "C-q" | "q" +"q" = "wclose" # "C-q" | "q" +"C-o" = "wonly" # "C-o" | "o" +"o" = "wonly" # "C-o" | "o" +"C-h" = "jump_view_left" # "C-h" | "h" | "left" +"h" = "jump_view_left" # "C-h" | "h" | "left" +"left" = "jump_view_left" # "C-h" | "h" | "left" +"C-j" = "jump_view_down" # "C-j" | "j" | "down" +"j" = "jump_view_down" # "C-j" | "j" | "down" +"down" = "jump_view_down" # "C-j" | "j" | "down" +"C-k" = "jump_view_up" # "C-k" | "k" | "up" +"k" = "jump_view_up" # "C-k" | "k" | "up" +"up" = "jump_view_up" # "C-k" | "k" | "up" +"C-l" = "jump_view_right" # "C-l" | "l" | "right" +"l" = "jump_view_right" # "C-l" | "l" | "right" +"right" = "jump_view_right" # "C-l" | "l" | "right" +"H" = "swap_view_left" # "H" +"J" = "swap_view_down" # "J" +"K" = "swap_view_up" # "K" +"L" = "swap_view_right" # "L" + +[keys.normal.space.w.n] # [keys.normal.space.w.n] +"C-s" = "hsplit_new" # "C-s" | "s" +"s" = "hsplit_new" # "C-s" | "s" +"C-v" = "vsplit_new" # "C-v" | "v" +"v" = "vsplit_new" # "C-v" | "v" + +[keys.normal.z] # [keys.normal.z] +"z" = "align_view_center" # "z" | "c" +"c" = "align_view_center" # "z" | "c" +"t" = "align_view_top" # "t" +"b" = "align_view_bottom" # "b" +"m" = "align_view_middle" # "m" +"k" = "scroll_up" # "k" | "up" +"up" = "scroll_up" # "k" | "up" +"j" = "scroll_down" # "j" | "down" +"down" = "scroll_down" # "j" | "down" +"C-b" = "page_up" # "C-b" | "pageup" +"pageup" = "page_up" # "C-b" | "pageup" +"C-f" = "page_down" # "C-f" | "pagedown" +"pagedown" = "page_down" # "C-f" | "pagedown" +"C-u" = "half_page_up" # "C-u" | "backspace" +"backspace" = "half_page_up" # "C-u" | "backspace" +"C-d" = "half_page_down" # "C-d" | "space" +"space" = "half_page_down" # "C-d" | "space" +"/" = "search" # "/" +"?" = "rsearch" # "?" +"n" = "search_next" # "n" +"N" = "search_prev" # "N" + +[keys.normal.Z] # [keys.normal.Z] +"z" = "align_view_center" # "z" | "c" +"c" = "align_view_center" # "z" | "c" +"t" = "align_view_top" # "t" +"b" = "align_view_bottom" # "b" +"m" = "align_view_middle" # "m" +"k" = "scroll_up" # "k" | "up" +"up" = "scroll_up" # "k" | "up" +"j" = "scroll_down" # "j" | "down" +"down" = "scroll_down" # "j" | "down" +"C-b" = "page_up" # "C-b" | "pageup" +"pageup" = "page_up" # "C-b" | "pageup" +"C-f" = "page_down" # "C-f" | "pagedown" +"pagedown" = "page_down" # "C-f" | "pagedown" +"C-u" = "half_page_up" # "C-u" | "backspace" +"backspace" = "half_page_up" # "C-u" | "backspace" +"C-d" = "half_page_down" # "C-d" | "space" +"space" = "half_page_down" # "C-d" | "space" +"/" = "search" # "/" +"?" = "rsearch" # "?" +"n" = "search_next" # "n" +"N" = "search_prev" # "N" + +[keys.select] +"h" = "extend_char_left" # "h" | "left" +"left" = "extend_char_left" # "h" | "left" +"j" = "extend_visual_line_down" # "j" | "down" +"down" = "extend_visual_line_down" # "j" | "down" +"k" = "extend_visual_line_up" # "k" | "up" +"up" = "extend_visual_line_up" # "k" | "up" +"l" = "extend_char_right" # "l" | "right" +"right" = "extend_char_right" # "l" | "right" +"w" = "extend_next_word_start" # "w" +"b" = "extend_prev_word_start" # "b" +"e" = "extend_next_word_end" # "e" +"W" = "extend_next_long_word_start" # "W" +"B" = "extend_prev_long_word_start" # "B" +"E" = "extend_next_long_word_end" # "E" +# error? "A-e" = "extend_parent_node_end" # "A-e" +# error? "A-b" = "extend_parent_node_start" # "A-b" +"n" = "extend_search_next" # "n" +"N" = "extend_search_prev" # "N" +"t" = "extend_till_char" # "t" +"f" = "extend_next_char" # "f" +"T" = "extend_till_prev_char" # "T" +"F" = "extend_prev_char" # "F" +"home" = "extend_to_line_start" # "home" +"end" = "extend_to_line_end" # "end" +"esc" = "exit_select_mode" # "esc" +"v" = "normal_mode" # "v" + +[keys.select.g] # [keys.select.g] +"k" = "extend_line_up" # "k" +"j" = "extend_line_down" # "j" + +[keys.insert] +"esc" = "normal_mode" # "esc" +"C-s" = "commit_undo_checkpoint" # "C-s" +"C-x" = "completion" # "C-x" +"C-r" = "insert_register" # "C-r" +"C-w" = "delete_word_backward" # "C-w" | "A-backspace" +"A-backspace" = "delete_word_backward" # "C-w" | "A-backspace" +"A-d" = "delete_word_forward" # "A-d" | "A-del" +"A-del" = "delete_word_forward" # "A-d" | "A-del" +"C-u" = "kill_to_line_start" # "C-u" +"C-k" = "kill_to_line_end" # "C-k" +"C-h" = "delete_char_backward" # "C-h" | "backspace" | "S-backspace" +"backspace" = "delete_char_backward" # "C-h" | "backspace" | "S-backspace" +"S-backspace" = "delete_char_backward" # "C-h" | "backspace" | "S-backspace" +"C-d" = "delete_char_forward" # "C-d" | "del" +"del" = "delete_char_forward" # "C-d" | "del" +"C-j" = "insert_newline" # "C-j" | "ret" +"ret" = "insert_newline" # "C-j" | "ret" +# error? "tab" = "smart_tab" # "tab" +"S-tab" = "insert_tab" # "S-tab" +"up" = "move_visual_line_up" # "up" +"down" = "move_visual_line_down" # "down" +"left" = "move_char_left" # "left" +"right" = "move_char_right" # "right" +"pageup" = "page_up" # "pageup" +"pagedown" = "page_down" # "pagedown" +"home" = "goto_line_start" # "home" +"end" = "goto_line_end_newline" # "end" diff --git a/config.toml b/config.toml new file mode 100644 index 0000000..f5d00e2 --- /dev/null +++ b/config.toml @@ -0,0 +1,406 @@ + +[keys.normal] +"d" = "move_char_left" # "h" | "left" +"left" = "move_char_left" # "h" | "left" +"h" = "move_visual_line_down" # "j" | "down" +"down" = "move_visual_line_down" # "j" | "down" +"t" = "move_visual_line_up" # "k" | "up" +"up" = "move_visual_line_up" # "k" | "up" +"n" = "move_char_right" # "l" | "right" +"right" = "move_char_right" # "l" | "right" +"y" = "find_till_char" # "t" +"u" = "find_next_char" # "f" +"Y" = "till_prev_char" # "T" +"U" = "find_prev_char" # "F" +"p" = "replace" # "r" +"P" = "replace_with_yanked" # "R" +"A-." = "repeat_last_motion" # "A-." +"~" = "switch_case" # "~" +"`" = "switch_to_lowercase" # "`" +"A-`" = "switch_to_uppercase" # "A-`" +"home" = "goto_line_start" # "home" +"end" = "goto_line_end" # "end" +"," = "move_next_word_start" # "w" +"x" = "move_prev_word_start" # "b" +"." = "move_next_word_end" # "e" +"<" = "move_next_long_word_start" # "W" +"X" = "move_prev_long_word_start" # "B" +">" = "move_next_long_word_end" # "E" +"k" = "select_mode" # "v" +"I" = "goto_line" # "G" + +"S" = "command_mode" # ":" +"c" = "insert_mode" # "i" +"C" = "insert_at_line_start" # "I" +"a" = "append_mode" # "a" +"A" = "insert_at_line_end" # "A" +"r" = "open_below" # "o" +"R" = "open_above" # "O" +"e" = "delete_selection" # "d" +"A-d" = "delete_selection_noyank" # "A-d" +"j" = "change_selection" # "c" +"A-c" = "change_selection_noyank" # "A-c" +"J" = "copy_selection_on_next_line" # "C" +"A-C" = "copy_selection_on_prev_line" # "A-C" +"o" = "select_regex" # "s" +"A-s" = "split_selection_on_newline" # "A-s" +# error? "A-minus" = "merge_selections" # "A-minus" +"A-_" = "merge_consecutive_selections" # "A-_" +"O" = "split_selection" # "S" +"s" = "collapse_selection" # ";" +"A-;" = "flip_selections" # "A-;" +"A-o" = "expand_selection" # "A-o" | "A-up" +"A-up" = "expand_selection" # "A-o" | "A-up" +"A-i" = "shrink_selection" # "A-i" | "A-down" +"A-down" = "shrink_selection" # "A-i" | "A-down" +"A-p" = "select_prev_sibling" # "A-p" | "A-left" +"A-left" = "select_prev_sibling" # "A-p" | "A-left" +"A-n" = "select_next_sibling" # "A-n" | "A-right" +"A-right" = "select_next_sibling" # "A-n" | "A-right" +# error? "A-e" = "move_parent_node_end" # "A-e" +# error? "A-b" = "move_parent_node_start" # "A-b" +"%" = "select_all" # "%" +"q" = "extend_line_below" # "x" +"Q" = "extend_to_line_bounds" # "X" +"A-x" = "shrink_to_line_bounds" # "A-x" + +"z" = "search" # "/" +"Z" = "rsearch" # "?" +"b" = "search_next" # "n" +"B" = "search_prev" # "N" +"*" = "search_selection" # "*" +"g" = "undo" # "u" +"G" = "redo" # "U" +"A-u" = "earlier" # "A-u" +"A-U" = "later" # "A-U" +"f" = "yank" # "y" +"l" = "paste_after" # "p" +"L" = "paste_before" # "P" +"\"" = "record_macro" # "Q" +"'" = "replay_macro" # "q" +"V" = "indent" # ">" +"W" = "unindent" # "<" +"]" = "format_selections" # "=" +"H" = "join_selections" # "J" +"A-J" = "join_selections_space" # "A-J" +"T" = "keep_selections" # "K" +"A-K" = "remove_selections" # "A-K" +"w" = "keep_primary_selection" # "," +"A-," = "remove_primary_selection" # "A-," + +# "q" = "record_macro" # "q" +#"Q" = "replay_macro" # "Q" + +"&" = "align_selections" # "&" +"{" = "trim_selections" # "_" +"(" = "rotate_selections_backward" # "(" +")" = "rotate_selections_forward" # ")" +"A-(" = "rotate_selection_contents_backward" # "A-(" +"A-)" = "rotate_selection_contents_forward" # "A-)" +"A-:" = "ensure_selections_forward" # "A-:" +"esc" = "normal_mode" # "esc" +"C-b" = "page_up" # "C-b" | "pageup" +"pageup" = "page_up" # "C-b" | "pageup" +"C-f" = "page_down" # "C-f" | "pagedown" +"pagedown" = "page_down" # "C-f" | "pagedown" +"C-u" = "half_page_up" # "C-u" +"C-d" = "half_page_down" # "C-d" + +"C-c" = "toggle_comments" # "C-c" +"C-i" = "jump_forward" # "C-i" | "tab" // tab == +"tab" = "jump_forward" # "C-i" | "tab" // tab == +"C-o" = "jump_backward" # "C-o" +"C-s" = "save_selection" # "C-s" + +"_" = "select_register" # "\"" +"|" = "shell_pipe" # "|" +"A-|" = "shell_pipe_to" # "A-|" +"!" = "shell_insert_output" # "!" +"A-!" = "shell_append_output" # "A-!" +"$" = "shell_keep_pipe" # "$" +"C-z" = "suspend" # "C-z" +"C-a" = "increment" # "C-a" +"C-x" = "decrement" # "C-x" + +[keys.normal.i] # [keys.normal.g] +"i" = "goto_file_start" # "g" +"." = "goto_last_line" # "e" +"u" = "goto_file" # "f" +"d" = "goto_line_start" # "h" +"n" = "goto_line_end" # "l" +"o" = "goto_first_nonwhitespace" # "s" +"e" = "goto_definition" # "d" +"E" = "goto_declaration" # "D" +"f" = "goto_type_definition" # "y" +"p" = "goto_reference" # "r" +"c" = "goto_implementation" # "i" +"y" = "goto_window_top" # "t" +"j" = "goto_window_center" # "c" +"x" = "goto_window_bottom" # "b" +"a" = "goto_last_accessed_file" # "a" +"m" = "goto_last_modified_file" # "m" +"b" = "goto_next_buffer" # "n" +"l" = "goto_previous_buffer" # "p" +"t" = "move_line_up" # "k" +"h" = "move_line_down" # "j" +"v" = "goto_last_modification" # "." + +[keys.normal.m] # [keys.normal.m] +"m" = "match_brackets" # "m" +"o" = "surround_add" # "s" +"p" = "surround_replace" # "r" +"e" = "surround_delete" # "d" +"a" = "select_textobject_around" # "a" +"c" = "select_textobject_inner" # "i" + +[keys.normal."/"] # [keys.normal."["] +"e" = "goto_prev_diag" # "d" +"E" = "goto_first_diag" # "D" +"i" = "goto_prev_change" # "g" +"I" = "goto_first_change" # "G" +"u" = "goto_prev_function" # "f" +"y" = "goto_prev_class" # "t" +"a" = "goto_prev_parameter" # "a" +"j" = "goto_prev_comment" # "c" +"Y" = "goto_prev_test" # "T" +"l" = "goto_prev_paragraph" # "p" +"space" = "add_newline_above" # "space" + +[keys.normal."="] # [keys.normal."]"] +"e" = "goto_next_diag" # "d" +"E" = "goto_last_diag" # "D" +"i" = "goto_next_change" # "g" +"I" = "goto_last_change" # "G" +"u" = "goto_next_function" # "f" +"y" = "goto_next_class" # "t" +"a" = "goto_next_parameter" # "a" +"j" = "goto_next_comment" # "c" +"Y" = "goto_next_test" # "T" +"l" = "goto_next_paragraph" # "p" +"space" = "add_newline_below" # "space" + +[keys.normal.C-w] # [keys.normal.C-w] +"C-w" = "rotate_view" # "C-w" | "w" +"w" = "rotate_view" # "C-w" | "w" +"C-s" = "hsplit" # "C-s" | "s" +"s" = "hsplit" # "C-s" | "s" +"C-v" = "vsplit" # "C-v" | "v" +"v" = "vsplit" # "C-v" | "v" +"C-t" = "transpose_view" # "C-t" | "t" +"t" = "transpose_view" # "C-t" | "t" +"u" = "goto_file_hsplit" # "f" +"U" = "goto_file_vsplit" # "F" +"C-q" = "wclose" # "C-q" | "q" +"q" = "wclose" # "C-q" | "q" +"C-o" = "wonly" # "C-o" | "o" +"o" = "wonly" # "C-o" | "o" +"C-h" = "jump_view_left" # "C-h" | "h" | "left" +"h" = "jump_view_left" # "C-h" | "h" | "left" +"left" = "jump_view_left" # "C-h" | "h" | "left" +"C-j" = "jump_view_down" # "C-j" | "j" | "down" +"j" = "jump_view_down" # "C-j" | "j" | "down" +"down" = "jump_view_down" # "C-j" | "j" | "down" +"C-k" = "jump_view_up" # "C-k" | "k" | "up" +"k" = "jump_view_up" # "C-k" | "k" | "up" +"up" = "jump_view_up" # "C-k" | "k" | "up" +"C-l" = "jump_view_right" # "C-l" | "l" | "right" +"l" = "jump_view_right" # "C-l" | "l" | "right" +"right" = "jump_view_right" # "C-l" | "l" | "right" +"N" = "swap_view_right" # "L" +"T" = "swap_view_up" # "K" +"D" = "swap_view_left" # "H" +"H" = "swap_view_down" # "J" + +[keys.normal.C-w.b] # [keys.normal.C-w.n] +"C-s" = "hsplit_new" # "C-s" | "s" +"s" = "hsplit_new" # "C-s" | "s" +"C-v" = "vsplit_new" # "C-v" | "v" +"v" = "vsplit_new" # "C-v" | "v" + +[keys.normal.space] +"u" = "file_picker" # "f" +"U" = "file_picker_in_current_directory" # "F" +"x" = "buffer_picker" # "b" +"h" = "jumplist_picker" # "j" +"o" = "symbol_picker" # "s" +"O" = "workspace_symbol_picker" # "S" +"e" = "diagnostics_picker" # "d" +"E" = "workspace_diagnostics_picker" # "D" +"a" = "code_action" # "a" +"minus" = "last_picker" # "'" + +"f" = "yank_joined_to_clipboard" # "y" +"F" = "yank_main_selection_to_clipboard" # "Y" +"l" = "paste_clipboard_after" # "p" +"L" = "paste_clipboard_before" # "P" +"P" = "replace_selections_with_clipboard" # "R" +"z" = "global_search" # "/" +"t" = "hover" # "k" +"p" = "rename_symbol" # "r" +"d" = "select_references_to_symbol_under_cursor" # "h" +"Z" = "command_palette" # "?" + +[keys.normal.space.i] # [keys.normal.space.g] +"n" = "dap_launch" # "l" +"p" = "dap_restart" # "r" +"x" = "dap_toggle_breakpoint" # "b" +"j" = "dap_continue" # "c" +"d" = "dap_pause" # "h" +"c" = "dap_step_in" # "i" +"r" = "dap_step_out" # "o" +"b" = "dap_next" # "n" +"k" = "dap_variables" # "v" +"y" = "dap_terminate" # "t" +"C-c" = "dap_edit_condition" # "C-c" +"C-l" = "dap_edit_log" # "C-l" +"." = "dap_enable_exceptions" # "e" +">" = "dap_disable_exceptions" # "E" + +[keys.normal.space.i.o] # [keys.normal.space.g.s] +"y" = "dap_switch_thread" # "t" +"u" = "dap_switch_stack_frame" # "f" + +[keys.normal.space.","] # [keys.normal.space.w] +"C-w" = "rotate_view" # "C-w" | "w" +"w" = "rotate_view" # "C-w" | "w" +"C-s" = "hsplit" # "C-s" | "s" +"s" = "hsplit" # "C-s" | "s" +"C-v" = "vsplit" # "C-v" | "v" +"v" = "vsplit" # "C-v" | "v" +"C-t" = "transpose_view" # "C-t" | "t" +"t" = "transpose_view" # "C-t" | "t" +"u" = "goto_file_hsplit" # "f" +"U" = "goto_file_vsplit" # "F" +"C-q" = "wclose" # "C-q" | "q" +"q" = "wclose" # "C-q" | "q" +"C-o" = "wonly" # "C-o" | "o" +"o" = "wonly" # "C-o" | "o" +"C-h" = "jump_view_left" # "C-h" | "h" | "left" +"h" = "jump_view_left" # "C-h" | "h" | "left" +"left" = "jump_view_left" # "C-h" | "h" | "left" +"C-j" = "jump_view_down" # "C-j" | "j" | "down" +"j" = "jump_view_down" # "C-j" | "j" | "down" +"down" = "jump_view_down" # "C-j" | "j" | "down" +"C-k" = "jump_view_up" # "C-k" | "k" | "up" +"k" = "jump_view_up" # "C-k" | "k" | "up" +"up" = "jump_view_up" # "C-k" | "k" | "up" +"C-l" = "jump_view_right" # "C-l" | "l" | "right" +"l" = "jump_view_right" # "C-l" | "l" | "right" +"right" = "jump_view_right" # "C-l" | "l" | "right" +"D" = "swap_view_left" # "H" +"H" = "swap_view_down" # "J" +"T" = "swap_view_up" # "K" +"N" = "swap_view_right" # "L" + +[keys.normal.space.",".b] # [keys.normal.space.w.n] +"C-s" = "hsplit_new" # "C-s" | "s" +"s" = "hsplit_new" # "C-s" | "s" +"C-v" = "vsplit_new" # "C-v" | "v" +"v" = "vsplit_new" # "C-v" | "v" + +[keys.normal.";"] # [keys.normal.z] +";" = "align_view_center" # "z" | "c" +"c" = "align_view_center" # "z" | "c" +"y" = "align_view_top" # "t" +"x" = "align_view_bottom" # "b" +"m" = "align_view_middle" # "m" +"t" = "scroll_up" # "k" | "up" +"up" = "scroll_up" # "k" | "up" +"h" = "scroll_down" # "j" | "down" +"down" = "scroll_down" # "j" | "down" +"C-b" = "page_up" # "C-b" | "pageup" +"pageup" = "page_up" # "C-b" | "pageup" +"C-f" = "page_down" # "C-f" | "pagedown" +"pagedown" = "page_down" # "C-f" | "pagedown" +"C-u" = "half_page_up" # "C-u" | "backspace" +"backspace" = "half_page_up" # "C-u" | "backspace" +"C-d" = "half_page_down" # "C-d" | "space" +"space" = "half_page_down" # "C-d" | "space" +"z" = "search" # "/" +"Z" = "rsearch" # "?" +"b" = "search_next" # "n" +"B" = "search_prev" # "N" + +[keys.normal.":"] # [keys.normal.Z] +";" = "align_view_center" # "z" | "c" +"c" = "align_view_center" # "z" | "c" +"y" = "align_view_top" # "t" +"x" = "align_view_bottom" # "b" +"m" = "align_view_middle" # "m" +"t" = "scroll_up" # "k" | "up" +"up" = "scroll_up" # "k" | "up" +"h" = "scroll_down" # "j" | "down" +"down" = "scroll_down" # "j" | "down" +"C-b" = "page_up" # "C-b" | "pageup" +"pageup" = "page_up" # "C-b" | "pageup" +"C-f" = "page_down" # "C-f" | "pagedown" +"pagedown" = "page_down" # "C-f" | "pagedown" +"C-u" = "half_page_up" # "C-u" | "backspace" +"backspace" = "half_page_up" # "C-u" | "backspace" +"C-d" = "half_page_down" # "C-d" | "space" +"space" = "half_page_down" # "C-d" | "space" +"z" = "search" # "/" +"Z" = "rsearch" # "?" +"b" = "search_next" # "n" +"B" = "search_prev" # "N" + +[keys.select] +"d" = "extend_char_left" # "h" | "left" +"left" = "extend_char_left" # "h" | "left" +"h" = "extend_visual_line_down" # "j" | "down" +"down" = "extend_visual_line_down" # "j" | "down" +"t" = "extend_visual_line_up" # "k" | "up" +"up" = "extend_visual_line_up" # "k" | "up" +"n" = "extend_char_right" # "l" | "right" +"right" = "extend_char_right" # "l" | "right" +"," = "extend_next_word_start" # "w" +"x" = "extend_prev_word_start" # "b" +"." = "extend_next_word_end" # "e" +"<" = "extend_next_long_word_start" # "W" +"X" = "extend_prev_long_word_start" # "B" +">" = "extend_next_long_word_end" # "E" +# error? "A-e" = "extend_parent_node_end" # "A-e" +# error? "A-b" = "extend_parent_node_start" # "A-b" +"b" = "extend_search_next" # "n" +"B" = "extend_search_prev" # "N" +"y" = "extend_till_char" # "t" +"u" = "extend_next_char" # "f" +"Y" = "extend_till_prev_char" # "T" +"U" = "extend_prev_char" # "F" +"home" = "extend_to_line_start" # "home" +"end" = "extend_to_line_end" # "end" +"esc" = "exit_select_mode" # "esc" +"k" = "normal_mode" # "v" + +[keys.select.i] # [keys.select.g] +"t" = "extend_line_up" # "k" +"h" = "extend_line_down" # "j" + +[keys.insert] +"esc" = "normal_mode" # "esc" +"C-s" = "commit_undo_checkpoint" # "C-s" +"C-x" = "completion" # "C-x" +"C-r" = "insert_register" # "C-r" +"C-w" = "delete_word_backward" # "C-w" | "A-backspace" +"A-backspace" = "delete_word_backward" # "C-w" | "A-backspace" +"A-d" = "delete_word_forward" # "A-d" | "A-del" +"A-del" = "delete_word_forward" # "A-d" | "A-del" +"C-u" = "kill_to_line_start" # "C-u" +"C-k" = "kill_to_line_end" # "C-k" +"C-h" = "delete_char_backward" # "C-h" | "backspace" | "S-backspace" +"backspace" = "delete_char_backward" # "C-h" | "backspace" | "S-backspace" +"S-backspace" = "delete_char_backward" # "C-h" | "backspace" | "S-backspace" +"C-d" = "delete_char_forward" # "C-d" | "del" +"del" = "delete_char_forward" # "C-d" | "del" +"C-j" = "insert_newline" # "C-j" | "ret" +"ret" = "insert_newline" # "C-j" | "ret" +# error? "tab" = "smart_tab" # "tab" +"S-tab" = "insert_tab" # "S-tab" +"up" = "move_visual_line_up" # "up" +"down" = "move_visual_line_down" # "down" +"left" = "move_char_left" # "left" +"right" = "move_char_right" # "right" +"pageup" = "page_up" # "pageup" +"pagedown" = "page_down" # "pagedown" +"home" = "goto_line_start" # "home" +"end" = "goto_line_end_newline" # "end" diff --git a/gen_dvorak_config.sh b/gen_dvorak_config.sh new file mode 100644 index 0000000..11709a6 --- /dev/null +++ b/gen_dvorak_config.sh @@ -0,0 +1,26 @@ +#!/bin/sh + +exit 1 +# run these manually need some fixup + +# this will mostly generate the default config, you need to go through and put in [keys.normal.g] etc +curl -s https://raw.githubusercontent.com/helix-editor/helix/master/helix-term/src/keymap/default.rs | grep '" =>' | sed -re 's/ *(".*") => (.*),/\1 = "\2" # \1/' -e 's/^("[^"]*") [|] ("[^"]*")([^=]*)= (.*)/\1 = \4\n\2\3= \4/g' | sed -r 's/^("[^"]*") [|] ("[^"]*")([^=]*)= (.*)/\1 = \4\n\2\3= \4/g' + +# keymap +# qwerty="qwertyuiop[]asdfghjkl;'zxcvbnm,./-=QWERTYUIOP{}ASDFGHJKL:\"ZXCVBNM<>?_+" +# dvorak="',.pyfgcrl/=aoeuidhtns-;qjkxbmwvz[]\"<>PYFGCRL?+AOEUIDHTNS_:QJKXBMWVZ{}" + +# keymap removed single and double quotes +qwerty="wertyuiop[]asdfghjkl;zxcvbnm,./-=WERTYUIOP{}ASDFGHJKL:ZXCVBNM<>?_+" +dvorak=",.pyfgcrl/=aoeuidhtns;qjkxbmwvz[]<>PYFGCRL?+AOEUIDHTNS:QJKXBMWVZ{}" + +# generate sed command: +for i in $(seq 0 $((${#qwerty} - 1))); do echo s@^\"[${qwerty:i:1}]\" = "(.*) # (\"[${qwerty:i:1}]\")"@\"${dvorak:i:1}\" = "\1 # \2"@; done | sed -e "s/^/-e '/" -e "s/$/'/" | tr '\n' ' ' + + +# manual sed for single/double quotes +# q -> ', ' > -, Q > \", \" > _ +# -e 's@^"[q]" = (.*) # ("[q]")@"'"'"'" = \1 # \2@' -e 's@^"['"'"']" = (.*) # ("['"'"']")@"minus" = \1 # \2@' -e 's@^"[Q]" = (.*) # ("[Q]")@"\\"" = \1 # \2@' -e 's@^"[\]["]" = (.*) # ("[\]["]")@"_" = \1 # \2@' + +# output of above with single quotes added back in +sed -r -e 's@^"[q]" = (.*) # ("[q]")@"'"'"'" = \1 # \2@' -e 's@^"['"'"']" = (.*) # ("['"'"']")@"minus" = \1 # \2@' -e 's@^"[Q]" = (.*) # ("[Q]")@"\\"" = \1 # \2@' -e 's@^"[\]["]" = (.*) # ("[\]["]")@"_" = \1 # \2@' -e 's@^"[w]" = (.*) # ("[w]")@"," = \1 # \2@' -e 's@^"[e]" = (.*) # ("[e]")@"." = \1 # \2@' -e 's@^"[r]" = (.*) # ("[r]")@"p" = \1 # \2@' -e 's@^"[t]" = (.*) # ("[t]")@"y" = \1 # \2@' -e 's@^"[y]" = (.*) # ("[y]")@"f" = \1 # \2@' -e 's@^"[u]" = (.*) # ("[u]")@"g" = \1 # \2@' -e 's@^"[i]" = (.*) # ("[i]")@"c" = \1 # \2@' -e 's@^"[o]" = (.*) # ("[o]")@"r" = \1 # \2@' -e 's@^"[p]" = (.*) # ("[p]")@"l" = \1 # \2@' -e 's@^"[[]" = (.*) # ("[[]")@"/" = \1 # \2@' -e 's@^"[]]" = (.*) # ("[]]")@"=" = \1 # \2@' -e 's@^"[a]" = (.*) # ("[a]")@"a" = \1 # \2@' -e 's@^"[s]" = (.*) # ("[s]")@"o" = \1 # \2@' -e 's@^"[d]" = (.*) # ("[d]")@"e" = \1 # \2@' -e 's@^"[f]" = (.*) # ("[f]")@"u" = \1 # \2@' -e 's@^"[g]" = (.*) # ("[g]")@"i" = \1 # \2@' -e 's@^"[h]" = (.*) # ("[h]")@"d" = \1 # \2@' -e 's@^"[j]" = (.*) # ("[j]")@"h" = \1 # \2@' -e 's@^"[k]" = (.*) # ("[k]")@"t" = \1 # \2@' -e 's@^"[l]" = (.*) # ("[l]")@"n" = \1 # \2@' -e 's@^"[;]" = (.*) # ("[;]")@"s" = \1 # \2@' -e 's@^"[z]" = (.*) # ("[z]")@";" = \1 # \2@' -e 's@^"[x]" = (.*) # ("[x]")@"q" = \1 # \2@' -e 's@^"[c]" = (.*) # ("[c]")@"j" = \1 # \2@' -e 's@^"[v]" = (.*) # ("[v]")@"k" = \1 # \2@' -e 's@^"[b]" = (.*) # ("[b]")@"x" = \1 # \2@' -e 's@^"[n]" = (.*) # ("[n]")@"b" = \1 # \2@' -e 's@^"[m]" = (.*) # ("[m]")@"m" = \1 # \2@' -e 's@^"[,]" = (.*) # ("[,]")@"w" = \1 # \2@' -e 's@^"[.]" = (.*) # ("[.]")@"v" = \1 # \2@' -e 's@^"[/]" = (.*) # ("[/]")@"z" = \1 # \2@' -e 's@^"[-]" = (.*) # ("[-]")@"[" = \1 # \2@' -e 's@^"[=]" = (.*) # ("[=]")@"]" = \1 # \2@' -e 's@^"[W]" = (.*) # ("[W]")@"<" = \1 # \2@' -e 's@^"[E]" = (.*) # ("[E]")@">" = \1 # \2@' -e 's@^"[R]" = (.*) # ("[R]")@"P" = \1 # \2@' -e 's@^"[T]" = (.*) # ("[T]")@"Y" = \1 # \2@' -e 's@^"[Y]" = (.*) # ("[Y]")@"F" = \1 # \2@' -e 's@^"[U]" = (.*) # ("[U]")@"G" = \1 # \2@' -e 's@^"[I]" = (.*) # ("[I]")@"C" = \1 # \2@' -e 's@^"[O]" = (.*) # ("[O]")@"R" = \1 # \2@' -e 's@^"[P]" = (.*) # ("[P]")@"L" = \1 # \2@' -e 's@^"[{]" = (.*) # ("[{]")@"?" = \1 # \2@' -e 's@^"[}]" = (.*) # ("[}]")@"+" = \1 # \2@' -e 's@^"[A]" = (.*) # ("[A]")@"A" = \1 # \2@' -e 's@^"[S]" = (.*) # ("[S]")@"O" = \1 # \2@' -e 's@^"[D]" = (.*) # ("[D]")@"E" = \1 # \2@' -e 's@^"[F]" = (.*) # ("[F]")@"U" = \1 # \2@' -e 's@^"[G]" = (.*) # ("[G]")@"I" = \1 # \2@' -e 's@^"[H]" = (.*) # ("[H]")@"D" = \1 # \2@' -e 's@^"[J]" = (.*) # ("[J]")@"H" = \1 # \2@' -e 's@^"[K]" = (.*) # ("[K]")@"T" = \1 # \2@' -e 's@^"[L]" = (.*) # ("[L]")@"N" = \1 # \2@' -e 's@^"[:]" = (.*) # ("[:]")@"S" = \1 # \2@' -e 's@^"[Z]" = (.*) # ("[Z]")@":" = \1 # \2@' -e 's@^"[X]" = (.*) # ("[X]")@"Q" = \1 # \2@' -e 's@^"[C]" = (.*) # ("[C]")@"J" = \1 # \2@' -e 's@^"[V]" = (.*) # ("[V]")@"K" = \1 # \2@' -e 's@^"[B]" = (.*) # ("[B]")@"X" = \1 # \2@' -e 's@^"[N]" = (.*) # ("[N]")@"B" = \1 # \2@' -e 's@^"[M]" = (.*) # ("[M]")@"M" = \1 # \2@' -e 's@^"[<]" = (.*) # ("[<]")@"W" = \1 # \2@' -e 's@^"[>]" = (.*) # ("[>]")@"V" = \1 # \2@' -e 's@^"[?]" = (.*) # ("[?]")@"Z" = \1 # \2@' -e 's@^"[_]" = (.*) # ("[_]")@"{" = \1 # \2@' -e 's@^"[+]" = (.*) # ("[+]")@"}" = \1 # \2@' config.orig.toml > config.dvorak.toml