Skip to content

Commit

Permalink
Changed keymap for telescope find files as the original keymap was
Browse files Browse the repository at this point in the history
causing it to lag (bc it was waiting for additional input since I put
leader f as find files and there were other leader f keymaps)

Changed config for neovim bufferline plugin to show # of errors and/or
warnings in a file
  • Loading branch information
jwyuen committed Oct 29, 2024
1 parent 095de70 commit 4941da4
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
6 changes: 4 additions & 2 deletions nix-config/home/nvim/keymaps.lua
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,14 @@
vim.g.mapleader = ","
local builtin = require("telescope.builtin")

vim.keymap.set("n", "<leader>f", builtin.find_files, { desc = "Telescope find files" })
vim.keymap.set("n", "<leader>ff", builtin.find_files, { desc = "Telescope find files" })
vim.keymap.set("n", "<leader>fg", builtin.live_grep, { desc = "Telescope live grep" })
vim.keymap.set("n", "<leader>fb", builtin.buffers, { desc = "Telescope buffers" })
vim.keymap.set("n", "<leader>fh", builtin.help_tags, { desc = "Telescope help tags" })
vim.keymap.set("n", "<leader>gd", builtin.lsp_definitions, { desc = "LSP go to definition" })
vim.keymap.set("n", "<leader>gt", builtin.lsp_type_definitions, { desc = "LSP go to type definition" })
vim.keymap.set("n", "<C-9>", "<cmd>bprev<CR>", { desc = "go to previous buffer" })
vim.keymap.set("n", "<C-0>", "<cmd>bnext<CR>", { desc = "go to next buffer" })
vim.keymap.set("n", "<leader>fd", function() MiniFiles.open() end, { desc = "open mini.files (filetree)" })
vim.keymap.set("n", "<leader>fd", function()
MiniFiles.open()
end, { desc = "open mini.files (filetree)" })
10 changes: 9 additions & 1 deletion nix-config/home/nvim/plugins/misc.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,12 @@
require("bufferline").setup({})
require("bufferline").setup({
options = {
diagnostics = "nvim_lsp",
diagnostics_indicator = function(count, level)
local icon = level:match("error") and "" or ""
return icon .. count
end,
},
})
require("gitsigns").setup()
require("ibl").setup()
require("lsp_lines").setup()
Expand Down

0 comments on commit 4941da4

Please sign in to comment.