local options = { noremap = true } vim.api.nvim_set_keymap('n', 'c', '"_c', options) -- Easily open splits vim.api.nvim_set_keymap('n', 'hs', 'split', options) vim.api.nvim_set_keymap('n', 'vs', 'vsplit', options) -- Copy the entire file vim.api.nvim_set_keymap('n', 'y', 'ggyG', options) -- Manually store session vim.api.nvim_set_keymap('n', '', 'mksession! ~/.cache//nvim/session/manual_session.vim', options) -- Restore manually stored session vim.api.nvim_set_keymap('n', '', 'source ~/.cache/nvim/session/manual_session.vim', options) -- Restore auto saved session created on exit vim.api.nvim_set_keymap('n', '', 'source ~/.cache/nvim/session/shutdown_session.vim', options) -- Replace all is aliased to S. vim.api.nvim_set_keymap('n', '', '%s//g', options) -- Navigating with guides vim.api.nvim_set_keymap('n', '', '/<++>"_c4l', options) vim.api.nvim_set_keymap('i', '', '/<++>"_c4l', options) vim.api.nvim_set_keymap('v', '', '/<++>"_c4l', options) -- Spell-check vim.api.nvim_set_keymap('n', 'o', 'setlocal spell! spelllang=en_au', options) vim.api.nvim_set_keymap('n', '', 'BufferMovePrevious', options) vim.api.nvim_set_keymap('n', '>', 'BufferMoveNext', options) vim.api.nvim_set_keymap('n', '', 'BufferGoto 1', options) vim.api.nvim_set_keymap('n', '', 'BufferGoto 2', options) vim.api.nvim_set_keymap('n', '', 'BufferGoto 3', options) vim.api.nvim_set_keymap('n', '', 'BufferGoto 4', options) vim.api.nvim_set_keymap('n', '', 'BufferGoto 5', options) vim.api.nvim_set_keymap('n', '', 'BufferGoto 6', options) vim.api.nvim_set_keymap('n', '', 'BufferGoto 7', options) vim.api.nvim_set_keymap('n', '', 'BufferGoto 8', options) vim.api.nvim_set_keymap('n', '', 'BufferGoto 9', options)