|
|
|
@ -1,3 +1,12 @@
|
|
|
|
|
local function map(mode, lhs, rhs, opts)
|
|
|
|
|
local options = { noremap = true }
|
|
|
|
|
if opts then
|
|
|
|
|
options = vim.tbl_extend("force", options, opts)
|
|
|
|
|
end
|
|
|
|
|
vim.api.nvim_set_keymap(mode, lhs, rhs, options)
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return {
|
|
|
|
|
-- Configure AstroNvim updates
|
|
|
|
|
updater = {
|
|
|
|
@ -18,7 +27,7 @@ return {
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
-- Set colorscheme to use
|
|
|
|
|
colorscheme = "astrodark",
|
|
|
|
|
colorscheme = "catppuccin",
|
|
|
|
|
|
|
|
|
|
-- Diagnostics configuration (for vim.diagnostics.config({...})) when diagnostics are on
|
|
|
|
|
diagnostics = {
|
|
|
|
@ -31,7 +40,7 @@ return {
|
|
|
|
|
formatting = {
|
|
|
|
|
-- control auto formatting on save
|
|
|
|
|
format_on_save = {
|
|
|
|
|
enabled = true, -- enable or disable format on save globally
|
|
|
|
|
enabled = false, -- enable or disable format on save globally
|
|
|
|
|
allow_filetypes = { -- enable format on save for specified filetypes only
|
|
|
|
|
-- "go",
|
|
|
|
|
},
|
|
|
|
@ -69,17 +78,7 @@ return {
|
|
|
|
|
-- 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
|
|
|
|
|
polish = function()
|
|
|
|
|
-- Set up custom filetypes
|
|
|
|
|
-- vim.filetype.add {
|
|
|
|
|
-- extension = {
|
|
|
|
|
-- foo = "fooscript",
|
|
|
|
|
-- },
|
|
|
|
|
-- filename = {
|
|
|
|
|
-- ["Foofile"] = "fooscript",
|
|
|
|
|
-- },
|
|
|
|
|
-- pattern = {
|
|
|
|
|
-- ["~/%.config/foo/.*"] = "fooscript",
|
|
|
|
|
-- },
|
|
|
|
|
-- }
|
|
|
|
|
vim.cmd "set nornu"
|
|
|
|
|
map("t", "jkl;", "<C-\\><C-n>'")
|
|
|
|
|
end,
|
|
|
|
|
}
|
|
|
|
|