2021-08-22 07:49:15 +00:00
|
|
|
-- IMPORTANT NOTE : This is the user config, can be edited. Will be preserved if updated with internal updater
|
2021-08-18 05:40:13 +00:00
|
|
|
|
2021-08-17 17:51:10 +00:00
|
|
|
local M = {}
|
|
|
|
|
2021-08-22 06:28:15 +00:00
|
|
|
-- non plugin ui configs, available without any plugins
|
2021-08-17 17:51:10 +00:00
|
|
|
M.ui = {
|
2021-08-22 07:49:15 +00:00
|
|
|
italic_comments = false,
|
|
|
|
|
|
|
|
-- theme to be used, to see all available themes, open the theme switcher by <leader> + th
|
2021-08-17 17:51:10 +00:00
|
|
|
theme = "onedark",
|
2021-08-19 09:06:49 +00:00
|
|
|
|
2021-08-22 07:49:15 +00:00
|
|
|
-- theme toggler, toggle between two themes, see theme_toggleer mappings
|
|
|
|
theme_toggler = {
|
|
|
|
enabled = false,
|
|
|
|
fav_themes = {
|
|
|
|
"onedark",
|
|
|
|
"gruvchad",
|
|
|
|
},
|
2021-08-17 17:51:10 +00:00
|
|
|
},
|
2021-08-19 09:06:49 +00:00
|
|
|
|
|
|
|
-- Enable this only if your terminal has the colorscheme set which nvchad uses
|
|
|
|
-- For Ex : if you have onedark set in nvchad , set onedark's bg color on your terminal
|
2021-08-19 09:09:27 +00:00
|
|
|
transparency = false,
|
2021-08-22 06:28:15 +00:00
|
|
|
}
|
2021-08-19 09:06:49 +00:00
|
|
|
|
2021-08-22 06:28:15 +00:00
|
|
|
-- plugin related ui options
|
|
|
|
M.ui.plugin = {
|
|
|
|
-- statusline related options
|
|
|
|
statusline = {
|
|
|
|
-- these are filetypes, not pattern matched
|
|
|
|
-- if a filetype is present in shown, it will always show the statusline, irrespective of filetypes in hidden
|
|
|
|
hidden = {},
|
|
|
|
shown = {},
|
|
|
|
-- default, round , slant , block , arrow
|
|
|
|
style = "default",
|
2021-08-17 17:51:10 +00:00
|
|
|
},
|
|
|
|
}
|
|
|
|
|
2021-08-22 06:28:15 +00:00
|
|
|
-- non plugin normal, available without any plugins
|
2021-08-17 17:51:10 +00:00
|
|
|
M.options = {
|
2021-08-22 07:49:15 +00:00
|
|
|
clipboard = "unnamedplus",
|
|
|
|
cmdheight = 1,
|
|
|
|
expandtab = true,
|
2021-08-17 17:51:10 +00:00
|
|
|
hidden = true,
|
|
|
|
ignorecase = true,
|
2021-08-22 07:49:15 +00:00
|
|
|
insert_nav = true, -- navigation in insertmode
|
|
|
|
mapleader = " ",
|
2021-08-17 17:51:10 +00:00
|
|
|
mouse = "a",
|
|
|
|
number = true,
|
2021-08-19 07:08:50 +00:00
|
|
|
-- relative numbers in normal mode tool at the bottom of options.lua
|
2021-08-17 17:51:10 +00:00
|
|
|
numberwidth = 2,
|
2021-08-22 07:49:15 +00:00
|
|
|
permanent_undo = true,
|
2021-08-17 17:51:10 +00:00
|
|
|
shiftwidth = 2,
|
|
|
|
smartindent = true,
|
2021-08-22 03:21:52 +00:00
|
|
|
tabstop = 8, -- Number of spaces that a <Tab> in the file counts for
|
2021-08-22 07:49:15 +00:00
|
|
|
timeoutlen = 400,
|
|
|
|
relativenumber = false,
|
|
|
|
ruler = false,
|
|
|
|
updatetime = 250,
|
2021-08-19 05:50:00 +00:00
|
|
|
-- used for updater
|
|
|
|
update_url = "https://github.com/NvChad/NvChad",
|
|
|
|
update_branch = "main",
|
2021-08-22 06:28:15 +00:00
|
|
|
}
|
2021-08-22 07:49:15 +00:00
|
|
|
|
2021-08-22 06:28:15 +00:00
|
|
|
-- these are plugin related options
|
|
|
|
M.options.plugin = {
|
|
|
|
autosave = false, -- autosave on changed text or insert mode leave
|
|
|
|
-- timeout to be used for using escape with a key combination, see mappings.plugin.better_escape
|
|
|
|
esc_insertmode_timeout = 300,
|
2021-08-17 17:51:10 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
-- enable and disable plugins (false for disable)
|
|
|
|
M.plugin_status = {
|
2021-08-22 07:49:15 +00:00
|
|
|
autosave = true, -- to autosave files
|
|
|
|
blankline = true, -- beautified blank lines
|
|
|
|
bufferline = true, -- buffer shown as tabs
|
|
|
|
cheatsheet = true, -- fuzzy search your commands/keymappings
|
|
|
|
colorizer = true,
|
|
|
|
comment = true, -- universal commentor
|
|
|
|
dashboard = true, -- a nice looking dashboard
|
|
|
|
esc_insertmode = true, -- escape from insert mode using custom keys
|
|
|
|
galaxyline = true, -- statusline
|
|
|
|
gitsigns = true, -- gitsigns in statusline
|
|
|
|
lspkind = true, -- lsp enhancements
|
|
|
|
lspsignature = true, -- lsp enhancements
|
|
|
|
neoformat = true, -- universal formatter
|
|
|
|
neoscroll = true, -- smooth scroll
|
|
|
|
telescope_media = true, -- see media files in telescope picker
|
|
|
|
truezen = true, -- no distraction mode for nvim
|
|
|
|
vim_fugitive = true, -- git in nvim
|
|
|
|
vim_matchup = true, -- % magic, match it but improved
|
2021-08-17 17:51:10 +00:00
|
|
|
}
|
|
|
|
|
2021-08-22 06:28:15 +00:00
|
|
|
-- mappings -- don't use a single keymap twice --
|
|
|
|
-- non plugin mappings
|
2021-08-17 17:51:10 +00:00
|
|
|
M.mappings = {
|
2021-08-22 07:49:15 +00:00
|
|
|
-- close current focused buffer
|
|
|
|
close_buffer = "<leader>x",
|
|
|
|
copy_whole_file = "<C-a>", -- copy all contents of the current buffer
|
|
|
|
|
|
|
|
-- navigation in insert mode, only if enabled in options
|
2021-08-17 17:51:10 +00:00
|
|
|
insert_nav = {
|
|
|
|
backward = "<C-h>",
|
|
|
|
end_of_line = "<C-e>",
|
2021-08-22 07:49:15 +00:00
|
|
|
forward = "<C-l>",
|
2021-08-17 17:51:10 +00:00
|
|
|
next_line = "<C-k>",
|
2021-08-22 07:49:15 +00:00
|
|
|
prev_line = "<C-j>",
|
|
|
|
top_of_line = "<C-a>",
|
2021-08-16 07:49:09 +00:00
|
|
|
},
|
2021-08-22 07:49:15 +00:00
|
|
|
|
|
|
|
line_number_toggle = "<leader>n", -- show or hide line number
|
|
|
|
new_buffer = "<S-t>", -- open a new buffer
|
|
|
|
new_tab = "<C-t>b", -- open a new vim tab
|
|
|
|
save_file = "<C-s>", -- save file using :w
|
|
|
|
theme_toggler = "<leader>tt", -- for theme toggler, see in ui.theme_toggler
|
|
|
|
|
|
|
|
-- terminal related mappings
|
|
|
|
terminal = {
|
|
|
|
-- multiple mappings can be given for esc_termmode and esc_hide_termmode
|
|
|
|
-- get out of terminal mode
|
|
|
|
esc_termmode = { "jk" }, -- multiple mappings allowed
|
|
|
|
-- get out of terminal mode and hide it
|
|
|
|
-- it does not close it, see pick_term mapping to see hidden terminals
|
|
|
|
esc_hide_termmode = { "JK" }, -- multiple mappings allowed
|
|
|
|
-- show hidden terminal buffers in a telescope picker
|
|
|
|
pick_term = "<leader>W",
|
|
|
|
-- below three are for spawning terminals
|
|
|
|
new_horizontal = "<leader>h",
|
|
|
|
new_vertical = "<leader>v",
|
|
|
|
new_window = "<leader>w",
|
|
|
|
},
|
|
|
|
|
|
|
|
-- update nvchad from nvchad, chadness 101
|
|
|
|
update_nvchad = "<leader>uu",
|
2021-08-22 06:28:15 +00:00
|
|
|
}
|
2021-08-22 07:49:15 +00:00
|
|
|
|
2021-08-22 06:28:15 +00:00
|
|
|
-- all plugins related mappings
|
|
|
|
-- to get short info about a plugin, see the respective string in plugin_status, if not present, then info here
|
|
|
|
M.mappings.plugin = {
|
|
|
|
bufferline = {
|
|
|
|
next_buffer = "<TAB>", -- next buffer
|
|
|
|
prev_buffer = "<S-Tab>", -- previous buffer
|
|
|
|
},
|
|
|
|
chadsheet = {
|
|
|
|
default_keys = "<leader>dk",
|
|
|
|
user_keys = "<leader>uk",
|
|
|
|
},
|
|
|
|
comment = {
|
|
|
|
toggle = "<leader>/", -- trigger comment on a single/selected lines/number prefix
|
|
|
|
},
|
|
|
|
dashboard = {
|
|
|
|
bookmarks = "<leader>bm",
|
|
|
|
new_file = "<leader>fn", -- basically create a new buffer
|
|
|
|
open = "<leader>db", -- open dashboard
|
|
|
|
session_load = "<leader>l", -- load a saved session
|
|
|
|
session_save = "<leader>s", -- save a session
|
|
|
|
},
|
|
|
|
-- note: this is an edditional mapping to escape, escape key will still work
|
|
|
|
better_escape = {
|
|
|
|
esc_insertmode = { "jk" }, -- multiple mappings allowed
|
|
|
|
},
|
|
|
|
nvimtree = {
|
|
|
|
toggle = "<C-n>", -- file manager
|
|
|
|
},
|
|
|
|
neoformat = {
|
|
|
|
format = "<leader>fm",
|
|
|
|
},
|
|
|
|
telescope = {
|
|
|
|
buffers = "<leader>fb",
|
|
|
|
find_files = "<leader>ff",
|
|
|
|
git_commits = "<leader>cm",
|
|
|
|
git_status = "<leader>gt",
|
|
|
|
help_tags = "<leader>fh",
|
|
|
|
live_grep = "<leader>fw",
|
|
|
|
oldfiles = "<leader>fo",
|
|
|
|
themes = "<leader>th",
|
|
|
|
},
|
|
|
|
telescope_media = {
|
|
|
|
media_files = "<leader>fp",
|
|
|
|
},
|
|
|
|
truezen = { -- distraction free modes mapping, hide statusline, tabline, line numbers
|
|
|
|
ataraxis_mode = "<leader>zz", -- center
|
|
|
|
focus_mode = "<leader>zf",
|
|
|
|
minimalistic_mode = "<leader>zm", -- as it is
|
|
|
|
},
|
|
|
|
vim_fugitive = {
|
|
|
|
diff_get_2 = "<leader>gh",
|
|
|
|
diff_get_3 = "<leader>gl",
|
|
|
|
git = "<leader>gs",
|
|
|
|
git_blame = "<leader>gb",
|
2021-08-16 07:49:09 +00:00
|
|
|
},
|
2021-08-12 11:58:03 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
return M
|