keymappings for neo

This commit is contained in:
Tim Gröger 2023-04-14 08:18:32 +02:00
parent 4afcfa7c33
commit 46df4817af
2 changed files with 24 additions and 16 deletions

View File

@ -16,17 +16,14 @@ return {
-- ["remote3"] = "github_user", -- GitHub user assume AstroNvim fork -- ["remote3"] = "github_user", -- GitHub user assume AstroNvim fork
}, },
}, },
-- Set colorscheme to use -- Set colorscheme to use
-- colorscheme = "astrodark", -- colorscheme = "astrodark",
colorscheme = "catppuccin-latte", colorscheme = "catppuccin-latte",
-- Diagnostics configuration (for vim.diagnostics.config({...})) when diagnostics are on -- Diagnostics configuration (for vim.diagnostics.config({...})) when diagnostics are on
diagnostics = { diagnostics = {
virtual_text = true, virtual_text = true,
underline = true, underline = true,
}, },
lsp = { lsp = {
-- customize lsp formatting options -- customize lsp formatting options
formatting = { formatting = {
@ -54,7 +51,6 @@ return {
-- "pyright" -- "pyright"
}, },
}, },
-- Configure require("lazy").setup() options -- Configure require("lazy").setup() options
lazy = { lazy = {
defaults = { lazy = true }, defaults = { lazy = true },
@ -65,7 +61,6 @@ return {
}, },
}, },
}, },
-- This function is run last and is a good place to configuring -- This function is run last and is a good place to configuring
-- augroups/autocommands and custom filetypes also this just pure lua so -- augroups/autocommands and custom filetypes also this just pure lua so
-- anything that doesn't fit in the normal config locations above can go here -- anything that doesn't fit in the normal config locations above can go here

View File

@ -11,7 +11,10 @@ return {
["<leader>bn"] = { "<cmd>tabnew<cr>", desc = "New tab" }, ["<leader>bn"] = { "<cmd>tabnew<cr>", desc = "New tab" },
["<leader>bD"] = { ["<leader>bD"] = {
function() function()
require("astronvim.utils.status").heirline.buffer_picker(function(bufnr) require("astronvim.utils.buffer").close(bufnr) end) require("astronvim.utils.status").heirline.buffer_picker(function(bufnr)
require("astronvim.utils.buffer").close(
bufnr)
end)
end, end,
desc = "Pick to close", desc = "Pick to close",
}, },
@ -20,6 +23,16 @@ return {
["<leader>b"] = { name = "Buffers" }, ["<leader>b"] = { name = "Buffers" },
-- quick save -- quick save
-- ["<C-s>"] = { ":w!<cr>", desc = "Save File" }, -- change description but the same command -- ["<C-s>"] = { ":w!<cr>", desc = "Save File" }, -- change description but the same command
["<S-g>"] = { "<C-w>k" },
["<S-r>"] = { "<C-w>j" },
["<S-n>"] = { "<C-w>h" },
["<S-t>"] = { "<C-w>l" },
["<C-g>"] = { "<C-w>K" },
["<C-r>"] = { "<C-w>J" },
["<C-n>"] = { "<C-w>H" },
["<C-t>"] = { "<C-w>L" },
["<leader>lgd"] = { vim.lsp.buf.hover() }
}, },
t = { t = {
-- setting a mapping to false will disable it -- setting a mapping to false will disable it