keymappings for neo
This commit is contained in:
parent
4afcfa7c33
commit
46df4817af
25
init.lua
25
init.lua
|
@ -1,38 +1,35 @@
|
|||
return {
|
||||
-- Configure AstroNvim updates
|
||||
updater = {
|
||||
remote = "origin", -- remote to use
|
||||
channel = "stable", -- "stable" or "nightly"
|
||||
version = "latest", -- "latest", tag name, or regex search like "v1.*" to only do updates before v2 (STABLE ONLY)
|
||||
branch = "nightly", -- branch name (NIGHTLY ONLY)
|
||||
commit = nil, -- commit hash (NIGHTLY ONLY)
|
||||
pin_plugins = nil, -- nil, true, false (nil will pin plugins on stable only)
|
||||
skip_prompts = false, -- skip prompts about breaking changes
|
||||
remote = "origin", -- remote to use
|
||||
channel = "stable", -- "stable" or "nightly"
|
||||
version = "latest", -- "latest", tag name, or regex search like "v1.*" to only do updates before v2 (STABLE ONLY)
|
||||
branch = "nightly", -- branch name (NIGHTLY ONLY)
|
||||
commit = nil, -- commit hash (NIGHTLY ONLY)
|
||||
pin_plugins = nil, -- nil, true, false (nil will pin plugins on stable only)
|
||||
skip_prompts = false, -- skip prompts about breaking changes
|
||||
show_changelog = true, -- show the changelog after performing an update
|
||||
auto_quit = false, -- automatically quit the current session after a successful update
|
||||
remotes = { -- easily add new remotes to track
|
||||
auto_quit = false, -- automatically quit the current session after a successful update
|
||||
remotes = { -- easily add new remotes to track
|
||||
-- ["remote_name"] = "https://remote_url.come/repo.git", -- full remote url
|
||||
-- ["remote2"] = "github_user/repo", -- GitHub user/repo shortcut,
|
||||
-- ["remote3"] = "github_user", -- GitHub user assume AstroNvim fork
|
||||
},
|
||||
},
|
||||
|
||||
-- Set colorscheme to use
|
||||
-- colorscheme = "astrodark",
|
||||
colorscheme = "catppuccin-latte",
|
||||
|
||||
-- Diagnostics configuration (for vim.diagnostics.config({...})) when diagnostics are on
|
||||
diagnostics = {
|
||||
virtual_text = true,
|
||||
underline = true,
|
||||
},
|
||||
|
||||
lsp = {
|
||||
-- customize lsp formatting options
|
||||
formatting = {
|
||||
-- control auto formatting on save
|
||||
format_on_save = {
|
||||
enabled = true, -- enable or disable format on save globally
|
||||
enabled = true, -- enable or disable format on save globally
|
||||
allow_filetypes = { -- enable format on save for specified filetypes only
|
||||
-- "go",
|
||||
},
|
||||
|
@ -54,7 +51,6 @@ return {
|
|||
-- "pyright"
|
||||
},
|
||||
},
|
||||
|
||||
-- Configure require("lazy").setup() options
|
||||
lazy = {
|
||||
defaults = { lazy = true },
|
||||
|
@ -65,7 +61,6 @@ return {
|
|||
},
|
||||
},
|
||||
},
|
||||
|
||||
-- This function is run last and is a good place to configuring
|
||||
-- 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
|
||||
|
|
15
mappings.lua
15
mappings.lua
|
@ -11,7 +11,10 @@ return {
|
|||
["<leader>bn"] = { "<cmd>tabnew<cr>", desc = "New tab" },
|
||||
["<leader>bD"] = {
|
||||
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,
|
||||
desc = "Pick to close",
|
||||
},
|
||||
|
@ -20,6 +23,16 @@ return {
|
|||
["<leader>b"] = { name = "Buffers" },
|
||||
-- quick save
|
||||
-- ["<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 = {
|
||||
-- setting a mapping to false will disable it
|
||||
|
|
Loading…
Reference in New Issue