feat: Add keybinds directory and changed some of the options
This commit is contained in:
@@ -0,0 +1,18 @@
|
|||||||
|
-- [[ Basic Keymaps ]]
|
||||||
|
-- See `:help vim.keymap.set()`
|
||||||
|
|
||||||
|
-- Clear highlights on search when pressing <Esc> in normal mode
|
||||||
|
-- See `:help hlsearch`
|
||||||
|
vim.keymap.set('n', '<Esc>', '<cmd>nohlsearch<CR>')
|
||||||
|
|
||||||
|
-- Diagnostic keymaps
|
||||||
|
vim.keymap.set('n', '<leader>q', vim.diagnostic.setloclist, { desc = 'Open diagnostic [Q]uickfix list' })
|
||||||
|
|
||||||
|
-- Keybinds to make split navigation easier.
|
||||||
|
-- Use CTRL+<hjkl> to switch between windows
|
||||||
|
--
|
||||||
|
-- See `:help wincmd` for a list of all window commands
|
||||||
|
vim.keymap.set('n', '<C-h>', '<C-w><C-h>', { desc = 'Move focus to the left window' })
|
||||||
|
vim.keymap.set('n', '<C-l>', '<C-w><C-l>', { desc = 'Move focus to the right window' })
|
||||||
|
vim.keymap.set('n', '<C-j>', '<C-w><C-j>', { desc = 'Move focus to the lower window' })
|
||||||
|
vim.keymap.set('n', '<C-k>', '<C-w><C-k>', { desc = 'Move focus to the upper window' })
|
||||||
@@ -29,6 +29,12 @@ vim.wo.signcolumn = 'yes'
|
|||||||
-- Prevent markdown from collapsing down
|
-- Prevent markdown from collapsing down
|
||||||
vim.o.foldenable = false
|
vim.o.foldenable = false
|
||||||
|
|
||||||
|
-- Preview substitutions live, as you type!
|
||||||
|
vim.o.inccommand = 'split'
|
||||||
|
|
||||||
|
-- Show which line your cursor is on
|
||||||
|
vim.o.cursorline = true
|
||||||
|
|
||||||
-- Tabs instead of spaces
|
-- Tabs instead of spaces
|
||||||
-- :h tabstop is the number of spaces for a tab character
|
-- :h tabstop is the number of spaces for a tab character
|
||||||
-- :h expandtab expands tabs into spaces
|
-- :h expandtab expands tabs into spaces
|
||||||
@@ -42,5 +48,3 @@ vim.o.completeopt = 'menuone,noinsert,noselect'
|
|||||||
|
|
||||||
-- Disable modelines, this removes some errors when opening text files
|
-- Disable modelines, this removes some errors when opening text files
|
||||||
vim.o.modeline = false
|
vim.o.modeline = false
|
||||||
|
|
||||||
vim.o.rtp = vim.o.rtp .. ",~/oxy/current-course"
|
|
||||||
|
|||||||
Reference in New Issue
Block a user