Initial Nvim Config Commit
This commit is contained in:
91
lua/plugins/cmp.lua
Normal file
91
lua/plugins/cmp.lua
Normal file
@@ -0,0 +1,91 @@
|
||||
-- print('test')
|
||||
|
||||
local enabled_lsps = {
|
||||
"pyright",
|
||||
"tsserver",
|
||||
"clangd",
|
||||
"gopls",
|
||||
"rust_analyzer",
|
||||
"taplo",
|
||||
"graphql"
|
||||
}
|
||||
|
||||
return {
|
||||
-- "L3MON4D3/LuaSnip",
|
||||
-- {
|
||||
"hrsh7th/nvim-cmp",
|
||||
|
||||
event = 'InsertEnter',
|
||||
|
||||
dependencies = {
|
||||
'hrsh7th/cmp-nvim-lsp',
|
||||
'L3MON4D3/LuaSnip',
|
||||
'saadparwaiz1/cmp_luasnip',
|
||||
},
|
||||
|
||||
config = function()
|
||||
local cmp = require'cmp'
|
||||
local ls = require('luasnip')
|
||||
|
||||
cmp.setup({
|
||||
snippets = {
|
||||
expand = function(args)
|
||||
ls.lsp_expand(args.body)
|
||||
end,
|
||||
},
|
||||
sources = {
|
||||
{ name = 'luasnip' },
|
||||
},
|
||||
})
|
||||
end,
|
||||
-- },
|
||||
-- 'saadparwaiz1/cmp_luasnip',
|
||||
|
||||
|
||||
-- config = function()
|
||||
--
|
||||
-- end,
|
||||
--
|
||||
-- config = function()
|
||||
-- local cmp = require('cmp')
|
||||
--
|
||||
-- cmp.setup({
|
||||
-- snippet = {
|
||||
-- expand = function(args)
|
||||
-- vim.fn["luasnip#anonymous"](args.body)
|
||||
-- end,
|
||||
-- },
|
||||
-- window = {
|
||||
-- completion = cmp.config.window.bordered(),
|
||||
-- documentation = cmp.config.window.bordered(),
|
||||
-- },
|
||||
-- mapping = cmp.mapping.preset.insert({
|
||||
-- ['<C-b>'] = cmp.mapping.scroll_docs(-4),
|
||||
-- ['<C-f>'] = cmp.mapping.scroll_docs(4),
|
||||
-- ['<C-Space>'] = cmp.mapping.complete(),
|
||||
-- ['<C-y>'] = cmp.config.disable,
|
||||
-- ['<C-e>'] = cmp.mapping({
|
||||
-- i = cmp.mapping.abort(),
|
||||
-- c = cmp.mapping.close(),
|
||||
-- }),
|
||||
-- ['<CR>'] = cmp.mapping.confirm({ select = true }),
|
||||
-- }),
|
||||
-- sources = cmp.config.sources({
|
||||
-- { name = 'nvim_lsp' },
|
||||
-- { name = 'luasnip' },
|
||||
-- }, {
|
||||
-- { name = 'buffer' },
|
||||
-- })
|
||||
-- })
|
||||
--
|
||||
-- end,
|
||||
--
|
||||
-- build = function()
|
||||
-- local lspconfig = require('lspconfig')
|
||||
-- for i, lsp in ipairs(enabled_lsps) do
|
||||
-- lspconfig[lsp].setup({
|
||||
-- capabilities = capabilities
|
||||
-- })
|
||||
-- end
|
||||
-- end,
|
||||
}
|
||||
6
lua/plugins/harpoon.lua
Normal file
6
lua/plugins/harpoon.lua
Normal file
@@ -0,0 +1,6 @@
|
||||
-- lua/plugins/harpoon.lua
|
||||
-- print('harpoon.lua loaded')
|
||||
|
||||
return {
|
||||
"ThePrimeagen/harpoon",
|
||||
}
|
||||
5
lua/plugins/indent_blankline.lua
Normal file
5
lua/plugins/indent_blankline.lua
Normal file
@@ -0,0 +1,5 @@
|
||||
-- lua/plugins/indent-blankline.lua
|
||||
|
||||
return {
|
||||
"lukas-reineke/indent-blankline.nvim",
|
||||
}
|
||||
44
lua/plugins/lsp.lua
Normal file
44
lua/plugins/lsp.lua
Normal file
@@ -0,0 +1,44 @@
|
||||
-- lua/plugins/lsp.lua
|
||||
-- print('lsp.lua loaded')
|
||||
|
||||
return {
|
||||
"neovim/nvim-lspconfig",
|
||||
lazy = false,
|
||||
priority = 900,
|
||||
|
||||
dependencies = {
|
||||
"williamboman/mason.nvim",
|
||||
"williamboman/mason-lspconfig.nvim",
|
||||
},
|
||||
|
||||
config = function()
|
||||
local lspconfig = require("lspconfig")
|
||||
local mason = require("mason")
|
||||
local masonlsp = require("mason-lspconfig")
|
||||
|
||||
mason.setup()
|
||||
masonlsp.setup()
|
||||
-- lspconfig.setup({})
|
||||
|
||||
lspconfig.pyright.setup({})
|
||||
lspconfig.tsserver.setup({})
|
||||
lspconfig.clangd.setup({})
|
||||
lspconfig.gopls.setup({})
|
||||
lspconfig.rust_analyzer.setup({})
|
||||
lspconfig.taplo.setup({})
|
||||
lspconfig.graphql.setup({})
|
||||
lspconfig.lua_ls.setup({
|
||||
settings = {
|
||||
diagnostics = {
|
||||
global = {
|
||||
'vim',
|
||||
'require'
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
lspconfig.vimls.setup({})
|
||||
-- lspconfig.rust_analyzer.setup({})
|
||||
-- lspconfig.lua_ls.setup({})
|
||||
end,
|
||||
}
|
||||
108
lua/plugins/lualine.lua
Normal file
108
lua/plugins/lualine.lua
Normal file
@@ -0,0 +1,108 @@
|
||||
-- lua/plugins/lualine.lua
|
||||
|
||||
return {
|
||||
"nvim-lualine/lualine.nvim",
|
||||
|
||||
dependencies = {
|
||||
"nvim-tree/nvim-web-devicons",
|
||||
},
|
||||
|
||||
config = function()
|
||||
local lualine = require('lualine')
|
||||
lualine.setup({
|
||||
options = {
|
||||
theme = 'auto',
|
||||
-- fmt = default,
|
||||
-- fmt = string.upper,
|
||||
|
||||
ignore_focus = {
|
||||
|
||||
},
|
||||
|
||||
refresh = {
|
||||
statusline = 100,
|
||||
tabline = 100,
|
||||
winbar = 100,
|
||||
},
|
||||
},
|
||||
sections = {
|
||||
lualine_a = {
|
||||
-- {
|
||||
-- 'windows'
|
||||
-- },
|
||||
{
|
||||
'diff',
|
||||
colored = true,
|
||||
diff_color = {
|
||||
added = 'LuaLineDiffAdd',
|
||||
modified = 'LuaLineDiffChange',
|
||||
removed = 'LuaLineDiffDelete',
|
||||
},
|
||||
},
|
||||
-- {
|
||||
-- 'buffers',
|
||||
-- show_filename_only = true,
|
||||
-- show_modified_status = false,
|
||||
--
|
||||
-- mode = 4,
|
||||
--
|
||||
-- filetype_names = {
|
||||
-- NvimTree = 'NvimTree'
|
||||
-- },
|
||||
-- },
|
||||
{
|
||||
'mode',
|
||||
fmt = function(str) return '[' .. str:sub(1,1) .. ']' end,
|
||||
},
|
||||
},
|
||||
lualine_b = {
|
||||
{ 'branch' }
|
||||
},
|
||||
lualine_c = {
|
||||
{
|
||||
'filename',
|
||||
file_status = true,
|
||||
newfile_status = false,
|
||||
path = 0,
|
||||
fmt = string.lower,
|
||||
shorting_target = 40,
|
||||
|
||||
symbols = {
|
||||
modified = '[+]',
|
||||
readonly = '[-]',
|
||||
unamed = '[No Name]',
|
||||
newfile = '[New]',
|
||||
},
|
||||
}
|
||||
},
|
||||
lualine_x = {
|
||||
{
|
||||
require("lazy.status").updates,
|
||||
cond = require("lazy.status").has_updates,
|
||||
color = { fg = "#ff9e64" },
|
||||
},
|
||||
{
|
||||
'encoding'
|
||||
},
|
||||
{
|
||||
'filetype',
|
||||
colored = true,
|
||||
icons_enabled = true,
|
||||
icon_only = true,
|
||||
icon = { align='center' }
|
||||
}
|
||||
},
|
||||
lualine_y = {
|
||||
{
|
||||
'progress',
|
||||
},
|
||||
},
|
||||
lualine_z = {
|
||||
{
|
||||
'location',
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
end,
|
||||
}
|
||||
10
lua/plugins/nvimtree.lua
Normal file
10
lua/plugins/nvimtree.lua
Normal file
@@ -0,0 +1,10 @@
|
||||
-- lua/plugins/nvimtree.lua
|
||||
-- print('nvimtree.lua loaded')
|
||||
|
||||
return {
|
||||
"nvim-tree/nvim-tree.lua",
|
||||
|
||||
dependencies = {
|
||||
"nvim-tree/nvim-web-devicons",
|
||||
},
|
||||
}
|
||||
12
lua/plugins/oxocarbon.lua
Normal file
12
lua/plugins/oxocarbon.lua
Normal file
@@ -0,0 +1,12 @@
|
||||
-- lua/plugin/oxocarbon.lua
|
||||
-- print('oxocarbon.lua loaded')
|
||||
|
||||
return {
|
||||
"nyoom-engineering/oxocarbon.nvim",
|
||||
"",
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
config = function()
|
||||
vim.cmd.colorscheme('oxocarbon')
|
||||
end,
|
||||
}
|
||||
11
lua/plugins/telescope.lua
Normal file
11
lua/plugins/telescope.lua
Normal file
@@ -0,0 +1,11 @@
|
||||
-- lua/plugins/telescope.lua
|
||||
-- print('telescope.lua loaded')
|
||||
|
||||
return {
|
||||
"nvim-telescope/telescope-file-browser.nvim",
|
||||
|
||||
dependencies = {
|
||||
"nvim-telescope/telescope.nvim",
|
||||
"nvim-lua/plenary.nvim"
|
||||
},
|
||||
}
|
||||
12
lua/plugins/treesitter.lua
Normal file
12
lua/plugins/treesitter.lua
Normal file
@@ -0,0 +1,12 @@
|
||||
-- lua/plugins/treesitter.lua
|
||||
-- print('treesitter.lua loaded')
|
||||
|
||||
return {
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
|
||||
dependencies = {
|
||||
"nvim-treesitter/nvim-treesitter-textobjects",
|
||||
},
|
||||
|
||||
build = ":TSUpdate",
|
||||
}
|
||||
20
lua/plugins/ui.lua
Normal file
20
lua/plugins/ui.lua
Normal file
@@ -0,0 +1,20 @@
|
||||
-- lua/plugin/oxocarbon.lua
|
||||
-- print('oxocarbon.lua loaded')
|
||||
|
||||
return {
|
||||
{
|
||||
"nyoom-engineering/oxocarbon.nvim",
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
},
|
||||
{
|
||||
'kepano/flexoki-neovim',
|
||||
name = 'flexoki',
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
},
|
||||
|
||||
-- config = function()
|
||||
-- vim.cmd.colorscheme('oxocarbon')
|
||||
-- end,
|
||||
}
|
||||
14
lua/plugins/wichkey.lua
Normal file
14
lua/plugins/wichkey.lua
Normal file
@@ -0,0 +1,14 @@
|
||||
return {
|
||||
"folke/which-key.nvim",
|
||||
event = "VeryLazy",
|
||||
init = function()
|
||||
vim.o.timeout = true
|
||||
vim.o.timeoutlen = 300
|
||||
end,
|
||||
opts = {
|
||||
|
||||
-- your configuration comes here
|
||||
-- or leave it empty to use the default settings
|
||||
-- refer to the configuration section below
|
||||
}
|
||||
}
|
||||
58
lua/stevenmm/init.lua
Normal file
58
lua/stevenmm/init.lua
Normal file
@@ -0,0 +1,58 @@
|
||||
require("stevenmm.set")
|
||||
require("stevenmm.remap")
|
||||
|
||||
require("stevenmm.lazy_init")
|
||||
|
||||
local augroup = vim.api.nvim_create_augroup
|
||||
local StevenmmGroup = augroup('Stevenmm', {})
|
||||
|
||||
local autocmd = vim.api.nvim_create_autocmd
|
||||
local yank_group = augroup('HighlightYank', {})
|
||||
|
||||
function R(name)
|
||||
require("plenary.reload").reload_module(name)
|
||||
end
|
||||
|
||||
vim.filetype.add({
|
||||
extension = {
|
||||
templ = 'templ',
|
||||
}
|
||||
})
|
||||
|
||||
autocmd('TextYankPost', {
|
||||
group = yank_group,
|
||||
pattern = '*',
|
||||
callback = function ()
|
||||
vim.highlight.on_yank({
|
||||
higroup = 'IncSearch',
|
||||
timeout = 40,
|
||||
})
|
||||
end,
|
||||
})
|
||||
|
||||
autocmd({"BufWritePre"}, {
|
||||
group = StevenmmGroup,
|
||||
pattern = "*",
|
||||
command = [[%s/\s\+$//e]],
|
||||
})
|
||||
|
||||
autocmd('LspAttach', {
|
||||
group = StevenmmGroup,
|
||||
callback = function (e)
|
||||
local opts = { buffer = e.buf }
|
||||
vim.keymap.set("n", "gd", function() vim.lsp.buf.definition() end, opts)
|
||||
vim.keymap.set("n", "K", function() vim.lsp.buf.hover() end, opts)
|
||||
vim.keymap.set("n", "<leader>vws", function() vim.lsp.buf.workspace_symbol() end, opts)
|
||||
vim.keymap.set("n", "<leader>vd", function() vim.diagnostic.open_float() end, opts)
|
||||
vim.keymap.set("n", "<leader>vca", function() vim.lsp.buf.code_action() end, opts)
|
||||
vim.keymap.set("n", "<leader>vrr", function() vim.lsp.buf.reference() end, opts)
|
||||
vim.keymap.set("n", "<leader>vrn", function() vim.lsp.buf.rename() end, opts)
|
||||
vim.keymap.set("i", "<C-h>", function() vim.lsp.buf.signature_help() end, opts)
|
||||
vim.keymap.set("n", "[d", function() vim.lsp.buf.goto_next() end, opts)
|
||||
vim.keymap.set("n", "]d", function() vim.lsp.buf.goto_prev() end, opts)
|
||||
end
|
||||
})
|
||||
|
||||
vim.g.netrw_browse_split = 0
|
||||
vim.g.netrw_banner = 0
|
||||
vim.g.netrw_winsize = 25
|
||||
30
lua/stevenmm/lazy/colors.lua
Normal file
30
lua/stevenmm/lazy/colors.lua
Normal file
@@ -0,0 +1,30 @@
|
||||
function ColorMyPencils(color)
|
||||
color = color or "rose-pine"
|
||||
vim.cmd.colorscheme(color)
|
||||
|
||||
vim.api.nvim_set_hl(0, "Normal", {bg = "none" })
|
||||
vim.api.nvim_set_hl(0, "NormalFloat", { bg = "none" })
|
||||
end
|
||||
|
||||
return {
|
||||
{
|
||||
"rose-pine/neovim",
|
||||
name = "rose-pine",
|
||||
config = function()
|
||||
require("rose-pine").setup({
|
||||
variant = "main",
|
||||
|
||||
styles = {
|
||||
bold = true,
|
||||
italic = false,
|
||||
transparency = true,
|
||||
},
|
||||
disable_background = true,
|
||||
})
|
||||
|
||||
vim.cmd("colorscheme rose-pine")
|
||||
|
||||
ColorMyPencils()
|
||||
end
|
||||
},
|
||||
}
|
||||
10
lua/stevenmm/lazy/init.lua
Normal file
10
lua/stevenmm/lazy/init.lua
Normal file
@@ -0,0 +1,10 @@
|
||||
return {
|
||||
{
|
||||
"nvim-lua/plenary.nvim",
|
||||
name = "plenary"
|
||||
},
|
||||
|
||||
"github/copilot.vim",
|
||||
"eandrju/cellular-automaton.nvim",
|
||||
"gpanders/editorconfig.nvim",
|
||||
}
|
||||
101
lua/stevenmm/lazy/lsp.lua
Normal file
101
lua/stevenmm/lazy/lsp.lua
Normal file
@@ -0,0 +1,101 @@
|
||||
return {
|
||||
"neovim/nvim-lspconfig",
|
||||
dependencies = {
|
||||
"williamboman/mason.nvim",
|
||||
"williamboman/mason-lspconfig.nvim",
|
||||
"hrsh7th/cmp-nvim-lsp",
|
||||
"hrsh7th/cmp-buffer",
|
||||
"hrsh7th/cmp-path",
|
||||
"hrsh7th/cmp-cmdline",
|
||||
"hrsh7th/nvim-cmp",
|
||||
"L3MON4D3/LuaSnip",
|
||||
"saadparwaiz1/cmp_luasnip",
|
||||
"j-hui/fidget.nvim",
|
||||
},
|
||||
|
||||
config = function()
|
||||
local cmp = require('cmp')
|
||||
local cmp_lsp = require("cmp_nvim_lsp")
|
||||
local capabilities = vim.tbl_deep_extend(
|
||||
"force",
|
||||
{},
|
||||
vim.lsp.protocol.make_client_capabilities(),
|
||||
cmp_lsp.default_capabilities())
|
||||
|
||||
require("fidget").setup({})
|
||||
require("mason").setup()
|
||||
require("mason-lspconfig").setup({
|
||||
ensure_installed = {
|
||||
"clangd",
|
||||
"lua_ls",
|
||||
"rust_analyzer",
|
||||
"tsserver",
|
||||
},
|
||||
handlers = {
|
||||
function(server_name) -- default handler (optional)
|
||||
|
||||
require("lspconfig")[server_name].setup {
|
||||
capabilities = capabilities
|
||||
}
|
||||
end,
|
||||
|
||||
["lua_ls"] = function()
|
||||
local lspconfig = require("lspconfig")
|
||||
lspconfig.lua_ls.setup {
|
||||
capabilities = capabilities,
|
||||
settings = {
|
||||
Lua = {
|
||||
diagnostics = {
|
||||
globals = { "vim", "it", "describe", "before_each", "after_each" },
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
end,
|
||||
|
||||
["clangd"] = function ()
|
||||
local lspconfig = require("lspconfig")
|
||||
lspconfig.clangd.setup({
|
||||
capabilities = capabilities,
|
||||
})
|
||||
end,
|
||||
}
|
||||
})
|
||||
|
||||
local cmp_select = { behavior = cmp.SelectBehavior.Select }
|
||||
|
||||
cmp.setup({
|
||||
snippet = {
|
||||
expand = function(args)
|
||||
require('luasnip').lsp_expand(args.body) -- For `luasnip` users.
|
||||
end,
|
||||
},
|
||||
mapping = cmp.mapping.preset.insert({
|
||||
['<C-p>'] = cmp.mapping.select_prev_item(cmp_select),
|
||||
['<C-n>'] = cmp.mapping.select_next_item(cmp_select),
|
||||
--['<C-y>'] = cmp.mapping.confirm({ select = true }),
|
||||
['<CR>'] = cmp.mapping.confirm({ select = true }),
|
||||
["<C-Space>"] = cmp.mapping.complete(),
|
||||
}),
|
||||
sources = cmp.config.sources({
|
||||
{ name = 'nvim_lsp' },
|
||||
{ name = 'luasnip' }, -- For luasnip users.
|
||||
}, {
|
||||
{ name = 'buffer' },
|
||||
})
|
||||
})
|
||||
|
||||
vim.diagnostic.config({
|
||||
-- update_in_insert = true,
|
||||
float = {
|
||||
focusable = false,
|
||||
style = "minimal",
|
||||
border = "rounded",
|
||||
source = "always",
|
||||
header = "",
|
||||
prefix = "",
|
||||
},
|
||||
})
|
||||
end
|
||||
}
|
||||
|
||||
132
lua/stevenmm/lazy/lualine.lua
Normal file
132
lua/stevenmm/lazy/lualine.lua
Normal file
@@ -0,0 +1,132 @@
|
||||
-- lua/plugins/lualine.lua
|
||||
local nvimtree = {
|
||||
filetypes = { "NvimTree" },
|
||||
sections = {
|
||||
lualine_c = { "buffers" },
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
return {
|
||||
"nvim-lualine/lualine.nvim",
|
||||
|
||||
dependencies = {
|
||||
"nvim-tree/nvim-web-devicons",
|
||||
},
|
||||
|
||||
config = function()
|
||||
local lualine = require('lualine')
|
||||
lualine.setup({
|
||||
options = {
|
||||
theme = 'rose-pine',
|
||||
globalstatus = false,
|
||||
-- fmt = default,
|
||||
-- fmt = string.upper,
|
||||
-- disabled_filetypes = {
|
||||
-- "NvimTree"
|
||||
-- },
|
||||
ignore_focus = {
|
||||
|
||||
},
|
||||
|
||||
refresh = {
|
||||
statusline = 100,
|
||||
tabline = 100,
|
||||
winbar = 100,
|
||||
},
|
||||
},
|
||||
sections = {
|
||||
lualine_a = {
|
||||
-- {
|
||||
-- 'windows'
|
||||
-- },
|
||||
{
|
||||
'diff',
|
||||
colored = true,
|
||||
diff_color = {
|
||||
added = 'LuaLineDiffAdd',
|
||||
modified = 'LuaLineDiffChange',
|
||||
removed = 'LuaLineDiffDelete',
|
||||
},
|
||||
},
|
||||
-- {
|
||||
-- 'buffers',
|
||||
-- show_filename_only = true,
|
||||
-- show_modified_status = false,
|
||||
--
|
||||
-- mode = 4,
|
||||
--
|
||||
-- filetype_names = {
|
||||
-- NvimTree = 'NvimTree'
|
||||
-- },
|
||||
-- },
|
||||
{
|
||||
'mode',
|
||||
-- fmt = function(str) return '[' .. str:sub(1,1) .. ']' end,
|
||||
},
|
||||
},
|
||||
lualine_b = {
|
||||
{ 'branch' }
|
||||
},
|
||||
lualine_c = {
|
||||
{
|
||||
'filetype',
|
||||
icons_enabled = true,
|
||||
icon_only = true,
|
||||
icon = { align = 'center' },
|
||||
separator = "",
|
||||
},
|
||||
{
|
||||
'filename',
|
||||
file_status = true,
|
||||
newfile_status = false,
|
||||
path = 0,
|
||||
fmt = string.lower,
|
||||
shorting_target = 40,
|
||||
|
||||
symbols = {
|
||||
modified = '[+]',
|
||||
readonly = '[-]',
|
||||
unamed = '[No Name]',
|
||||
newfile = '[New]',
|
||||
},
|
||||
}
|
||||
},
|
||||
lualine_x = {
|
||||
{
|
||||
require("lazy.status").updates,
|
||||
cond = require("lazy.status").has_updates,
|
||||
color = { fg = "#ff9e64" },
|
||||
},
|
||||
{
|
||||
'diagnostics',
|
||||
|
||||
},
|
||||
-- {
|
||||
-- 'filetype',
|
||||
-- colored = true,
|
||||
-- icons_enabled = true,
|
||||
-- icon_only = true,
|
||||
-- icon = { align = 'center' }
|
||||
-- }
|
||||
},
|
||||
lualine_y = {
|
||||
{
|
||||
'location',
|
||||
},
|
||||
},
|
||||
lualine_z = {
|
||||
{
|
||||
'datetime',
|
||||
icons_enabled = true,
|
||||
icon = { '' },
|
||||
style = '%H:%M',
|
||||
},
|
||||
},
|
||||
},
|
||||
extensions = {
|
||||
nvimtree
|
||||
}
|
||||
})
|
||||
end,
|
||||
}
|
||||
30
lua/stevenmm/lazy/mininvim.lua
Normal file
30
lua/stevenmm/lazy/mininvim.lua
Normal file
@@ -0,0 +1,30 @@
|
||||
return {
|
||||
{
|
||||
'echasnovski/mini.pairs',
|
||||
version = false,
|
||||
},
|
||||
{
|
||||
'echasnovski/mini.move',
|
||||
version = false,
|
||||
},
|
||||
{
|
||||
'echasnovski/mini.surround',
|
||||
version = false,
|
||||
},
|
||||
{
|
||||
'echasnovski/mini.indentscope',
|
||||
version = false,
|
||||
},
|
||||
{
|
||||
'echasnovski/mini.comment',
|
||||
version = false,
|
||||
},
|
||||
|
||||
config = function ()
|
||||
require('mini.pairs').setup()
|
||||
require('mini.move').setup()
|
||||
require('mini.surround').setup()
|
||||
require('mini.indentscope').setup()
|
||||
require('mini.comment').setup()
|
||||
end
|
||||
}
|
||||
26
lua/stevenmm/lazy/nvimtree.lua
Normal file
26
lua/stevenmm/lazy/nvimtree.lua
Normal file
@@ -0,0 +1,26 @@
|
||||
return {
|
||||
"nvim-tree/nvim-tree.lua",
|
||||
lazy = false,
|
||||
dependencies = {
|
||||
"nvim-tree/nvim-web-devicons",
|
||||
},
|
||||
|
||||
config = function()
|
||||
require("nvim-tree").setup({
|
||||
renderer = {
|
||||
icons = {
|
||||
web_devicons = {
|
||||
file = {
|
||||
enable = true,
|
||||
color = true,
|
||||
},
|
||||
folder = {
|
||||
enable = true,
|
||||
color = true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
end,
|
||||
}
|
||||
11
lua/stevenmm/lazy/telescope.lua
Normal file
11
lua/stevenmm/lazy/telescope.lua
Normal file
@@ -0,0 +1,11 @@
|
||||
-- lua/plugins/telescope.lua
|
||||
-- print('telescope.lua loaded')
|
||||
|
||||
return {
|
||||
"nvim-telescope/telescope-file-browser.nvim",
|
||||
|
||||
dependencies = {
|
||||
"nvim-telescope/telescope.nvim",
|
||||
-- "nvim-lua/plenary.nvim"
|
||||
},
|
||||
}
|
||||
12
lua/stevenmm/lazy/treesitter.lua
Normal file
12
lua/stevenmm/lazy/treesitter.lua
Normal file
@@ -0,0 +1,12 @@
|
||||
-- lua/plugins/treesitter.lua
|
||||
-- print('treesitter.lua loaded')
|
||||
|
||||
return {
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
|
||||
dependencies = {
|
||||
"nvim-treesitter/nvim-treesitter-textobjects",
|
||||
},
|
||||
|
||||
build = ":TSUpdate",
|
||||
}
|
||||
14
lua/stevenmm/lazy/wichkey.lua
Normal file
14
lua/stevenmm/lazy/wichkey.lua
Normal file
@@ -0,0 +1,14 @@
|
||||
return {
|
||||
"folke/which-key.nvim",
|
||||
event = "VeryLazy",
|
||||
init = function()
|
||||
vim.o.timeout = true
|
||||
vim.o.timeoutlen = 300
|
||||
end,
|
||||
opts = {
|
||||
|
||||
-- your configuration comes here
|
||||
-- or leave it empty to use the default settings
|
||||
-- refer to the configuration section below
|
||||
}
|
||||
}
|
||||
17
lua/stevenmm/lazy_init.lua
Normal file
17
lua/stevenmm/lazy_init.lua
Normal file
@@ -0,0 +1,17 @@
|
||||
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
||||
if not vim.loop.fs_stat(lazypath) then
|
||||
vim.fn.system({
|
||||
"git",
|
||||
"clone",
|
||||
"--filter=blob:none",
|
||||
"https://github.com/folke/lazy.nvim.git",
|
||||
"--branch=stable", -- latest stable release
|
||||
lazypath,
|
||||
})
|
||||
end
|
||||
vim.opt.rtp:prepend(lazypath)
|
||||
|
||||
require("lazy").setup({
|
||||
spec = "stevenmm.lazy",
|
||||
change_detection = { notify = false }
|
||||
})
|
||||
7
lua/stevenmm/remap.lua
Normal file
7
lua/stevenmm/remap.lua
Normal file
@@ -0,0 +1,7 @@
|
||||
vim.g.mapleader = " "
|
||||
|
||||
local keyset = vim.keymap.set
|
||||
|
||||
keyset("n", "<leader>ma", ":Mason<CR>", { silent = true })
|
||||
keyset("n", "<leader>na", ":NvimTreeToggle<CR>", { silent = true })
|
||||
keyset("n", "<leader>fb", ":Telescope file_browser path=%:p:h<CR>", { noremap = true, silent = true })
|
||||
34
lua/stevenmm/set.lua
Normal file
34
lua/stevenmm/set.lua
Normal file
@@ -0,0 +1,34 @@
|
||||
-- vim.opt.guicursor = "n-v-c:block,i-ci-ve:ver25,r-cr:hor20,o:hor50/,a:blinkwait700-blinkoff400-blinkon250-Cursor/lCursor/,sm:block-blinkwait175-blinkoff150-blinkon175"
|
||||
|
||||
vim.opt.number = true
|
||||
vim.opt.relativenumber = true
|
||||
|
||||
vim.opt.encoding = 'UTF-8'
|
||||
vim.opt.guifont = 'monospace'
|
||||
|
||||
vim.opt.tabstop = 4
|
||||
vim.opt.softtabstop = 4
|
||||
vim.shiftwidth = 4
|
||||
vim.opt.expandtab = true
|
||||
|
||||
vim.opt.smartindent = true
|
||||
|
||||
vim.opt.wrap = false
|
||||
|
||||
vim.opt.swapfile = false
|
||||
vim.opt.backup = false
|
||||
vim.opt.undodir = os.getenv("XDG_CONFIG_HOME") .. "/.vim/undodir"
|
||||
vim.opt.undofile = true
|
||||
|
||||
vim.opt.hlsearch = false
|
||||
vim.opt.incsearch = true
|
||||
|
||||
vim.opt.termguicolors = true
|
||||
|
||||
vim.opt.scrolloff = 8
|
||||
vim.opt.signcolumn = "yes"
|
||||
vim.opt.isfname:append("@-@")
|
||||
|
||||
vim.opt.updatetime = 50
|
||||
|
||||
vim.opt.colorcolumn = "80"
|
||||
Reference in New Issue
Block a user