switched to lazy.nvim and clean up a bit

This commit is contained in:
iris committed 2023-02-16 01:24:40 -05:00
1 parent 72bf7e727a
commit 11bb713b60
19 files changed
+289 -330

No files matched your search

+1 -1
View File
@@ -1 +1 @@
plugin lazy-lock.json
+8 -8
View File
@@ -1,9 +1,9 @@
for _, name in ipairs({ for _, name in ipairs({
'reload', "reload",
'settings', "settings",
'mappings', "mappings",
'plugins', "plugins",
'neovide', "neovide",
'theme', "theme",
'preview' "preview"
}) do require('config.' .. name) end }) do require("config." .. name) end
+17 -17
View File
@@ -1,35 +1,35 @@
local on_attach = function(_, bufnr) local on_attach = function(_, bufnr)
vim.api.nvim_buf_set_option(bufnr, 'omnifunc', 'v:lua.vim.lsp.omnifunc') vim.api.nvim_buf_set_option(bufnr, "omnifunc", "v:lua.vim.lsp.omnifunc")
vim.o.signcolumn = 'yes' vim.o.signcolumn = "yes"
local map = function(from, to) local map = function(from, to)
vim.keymap.set('n', from, to, vim.keymap.set("n", from, to,
{ noremap = true, silent = true, buffer = bufnr } { noremap = true, silent = true, buffer = bufnr }
) )
end end
map('gd', vim.lsp.buf.definition) map("gd", vim.lsp.buf.definition)
map('gr', vim.lsp.buf.references) map("gr", vim.lsp.buf.references)
map('gi', vim.lsp.buf.implementation) map("gi", vim.lsp.buf.implementation)
map('gD', vim.lsp.buf.declaration) map("gD", vim.lsp.buf.declaration)
map('K', vim.lsp.buf.hover) map("K", vim.lsp.buf.hover)
map('<C-k>', vim.lsp.buf.signature_help) map("<C-k>", vim.lsp.buf.signature_help)
map('<leader>wa', vim.lsp.buf.add_workspace_folder) map("<leader>wa", vim.lsp.buf.add_workspace_folder)
map('<leader>wr', vim.lsp.buf.remove_workspace_folder) map("<leader>wr", vim.lsp.buf.remove_workspace_folder)
map('<leader>wl', function() map("<leader>wl", function()
print(vim.inspect(vim.lsp.buf.list_workspace_folders())) print(vim.inspect(vim.lsp.buf.list_workspace_folders()))
end) end)
map('<leader>D', vim.lsp.buf.type_definition) map("<leader>D", vim.lsp.buf.type_definition)
map('<leader>rn', vim.lsp.buf.rename) map("<leader>rn", vim.lsp.buf.rename)
map('<leader>ca', vim.lsp.buf.code_action) map("<leader>ca", vim.lsp.buf.code_action)
map('<leader>fm', function() map("<leader>fm", function()
vim.lsp.buf.format { async = true } vim.lsp.buf.format { async = true }
end) end)
end end
local capabilities = require 'cmp_nvim_lsp'.default_capabilities( local capabilities = require "cmp_nvim_lsp".default_capabilities(
vim.lsp.protocol.make_client_capabilities() vim.lsp.protocol.make_client_capabilities()
) )
+37 -37
View File
@@ -1,56 +1,56 @@
local u = require 'config.utils' local u = require "config.utils"
-- terminal -- terminal
local m = u.mapping local m = u.mapping
m.map('t', '<esc>', '<C-\\><C-n>') m.map("t", "<esc>", "<C-\\><C-n>")
m.map('t', '<C-n>', '<C-\\><C-n><C-w>h') m.map("t", "<C-n>", "<C-\\><C-n><C-w>h")
m.map('t', '<C-e>', '<C-\\><C-n><C-w>j') m.map("t", "<C-e>", "<C-\\><C-n><C-w>j")
m.map('t', '<C-i>', '<C-\\><C-n><C-w>k') m.map("t", "<C-i>", "<C-\\><C-n><C-w>k")
m.map('t', '<C-o>', '<C-\\><C-n><C-w>l') m.map("t", "<C-o>", "<C-\\><C-n><C-w>l")
m.nmap('<leader>tm', '<cmd>belowright 7sp<cr><cmd>term<cr><cmd>setlocal nonu<cr>A') m.nmap("<leader>tm", "<cmd>belowright 7sp<cr><cmd>term<cr><cmd>setlocal nonu<cr>A")
-- off search highlight when escape is pressed -- off search highlight when escape is pressed
m.nmap('<esc>', '<cmd>noh<cr><esc>') m.nmap("<esc>", "<cmd>noh<cr><esc>")
-- spell checking -- spell checking
m.cmd('<leader>spl', 'setlocal spell spelllang=en_us') m.cmd("<leader>spl", "setlocal spell spelllang=en_us")
m.cmd('<leader>spL', 'setlocal nospell') m.cmd("<leader>spL", "setlocal nospell")
-- lsp -- lsp
m.nmap('E', vim.diagnostic.open_float) m.nmap("E", vim.diagnostic.open_float)
m.nmap('[d', vim.diagnostic.goto_prev) m.nmap("[d", vim.diagnostic.goto_prev)
m.nmap(']d', vim.diagnostic.goto_next) m.nmap("]d", vim.diagnostic.goto_next)
m.nmap('<leader>q', vim.diagnostic.setloclist) m.nmap("<leader>q", vim.diagnostic.setloclist)
-- colemak-dh -- colemak-dh
local l = u.layout local l = u.layout
l.swap('n', 'h') l.swap("n", "h")
l.swap('e', 'j') l.swap("e", "j")
l.swap('i', 'k') l.swap("i", "k")
l.swap('o', 'l') l.swap("o", "l")
l.map('e','gj') l.map("e","gj")
l.map('i','gk') l.map("i","gk")
l.swap('<C-w>n', '<C-w>h') l.swap("<C-w>n", "<C-w>h")
l.swap('<C-w>e', '<C-w>j') l.swap("<C-w>e", "<C-w>j")
l.swap('<C-w>i', '<C-w>k') l.swap("<C-w>i", "<C-w>k")
l.swap('<C-w>o', '<C-w>l') l.swap("<C-w>o", "<C-w>l")
l.swap('<C-w>N', '<C-w>H') l.swap("<C-w>N", "<C-w>H")
l.swap('<C-w>E', '<C-w>J') l.swap("<C-w>E", "<C-w>J")
l.swap('<C-w>I', '<C-w>K') l.swap("<C-w>I", "<C-w>K")
l.swap('<C-w>O', '<C-w>L') l.swap("<C-w>O", "<C-w>L")
l.swap('N', 'H') l.swap("N", "H")
l.swap('O', 'L') l.swap("O", "L")
l.map('<C-n>', '<C-w>h') l.map("<C-n>", "<C-w>h")
l.map('<C-e>', '<C-w>j') l.map("<C-e>", "<C-w>j")
l.map('<C-i>', '<C-w>k') l.map("<C-i>", "<C-w>k")
l.map('<C-o>', '<C-w>l') l.map("<C-o>", "<C-w>l")
l.map('<C-,>', '<cmd>vert res -1<CR>') l.map("<C-,>", "<cmd>vert res -1<CR>")
l.map('<C-.>', '<cmd>vert res +1<CR>') l.map("<C-.>", "<cmd>vert res +1<CR>")
-- ascension -- ascension
m.map('x','<leader>p', '\"_dp') m.map("x","<leader>p", "\"_dp")
+12 -23
View File
@@ -1,26 +1,15 @@
local fn = vim.fn
-- bootstrap -- bootstrap
local install_path = fn.stdpath('data')..'/site/pack/packer/start/packer.nvim' local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if fn.empty(fn.glob(install_path)) > 0 then if not vim.loop.fs_stat(lazypath) then
PACKER_BOOTSTRAP = fn.system({'git', 'clone', '--depth', '1', 'https://github.com/wbthomason/packer.nvim', install_path}) vim.fn.system({
vim.cmd [[packadd packer.nvim]] "git",
"clone",
"--filter=blob:none",
"https://github.com/folke/lazy.nvim.git",
"--branch=stable", -- latest stable release
lazypath,
})
end end
vim.opt.rtp:prepend(lazypath)
local packer = require('packer') require("lazy").setup("plugins")
packer.startup(function(use)
use 'wbthomason/packer.nvim'
-- plugin categories
require 'config.plugins.telescope'(use)
require 'config.plugins.tree'(use)
require 'config.plugins.cmp'(use)
require 'config.plugins.lsp'(use)
require 'config.plugins.visual'(use)
require 'config.plugins.util'(use)
-- sync if bootstrapped
if PACKER_BOOTSTRAP then
require('packer').sync()
end
end)
-36
View File
@@ -1,36 +0,0 @@
return function(use)
use 'hrsh7th/cmp-nvim-lsp'
use 'hrsh7th/cmp-buffer'
use 'hrsh7th/cmp-path'
use 'hrsh7th/cmp-cmdline'
use {
'hrsh7th/nvim-cmp',
config = function()
local cmp = require 'cmp'
cmp.setup({
snippet = {
expand = function(args)
require('luasnip').lsp_expand(args.body)
end
},
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-e>'] = cmp.mapping.abort(),
['<cr>'] = cmp.mapping.confirm({ select = true }),
['<tab>'] = cmp.mapping.select_next_item(),
}),
sources = cmp.config.sources({
{ name = 'nvim_lsp' },
{ name = 'luasnip' },
{ name = 'path' },
{ name = 'neorg' },
}),
})
end
}
use 'L3MON4D3/LuaSnip'
use 'saadparwaiz1/cmp_luasnip'
end
-39
View File
@@ -1,39 +0,0 @@
return function(use)
use {
'nvim-telescope/telescope.nvim',
tag = '0.1.0',
requires = { 'nvim-lua/plenary.nvim' },
config = function()
require 'telescope'.setup {}
local u = require 'config.utils'.mapping
u.cmd('<leader>ff', 'Telescope find_files')
u.cmd('<leader>fg', 'Telescope live_grep')
u.cmd('<leader>fb', 'Telescope buffers')
u.cmd('<leader>fh', 'Telescope help_tags')
end
}
use {
'nvim-telescope/telescope-fzf-native.nvim',
run = 'make',
requires = { 'nvim-telescope/telescope.nvim' },
-- doesn't work?
-- config = function() require 'telescope'.load_extension('fzf') end
}
use {
'nvim-telescope/telescope-ui-select.nvim',
requires = { 'nvim-telescope/telescope.nvim' },
config = function() require 'telescope'.load_extension('ui-select') end
}
use({
'ziontee113/icon-picker.nvim',
requires = { 'stevearc/dressing.nvim' },
config = function()
require('icon-picker').setup {}
local u = require 'config.utils'.mapping
u.cmd('<leader>fi', 'IconPickerYank alt_font symbols nerd_font emoji')
vim.keymap.set('i', '<c-s>', '<cmd>IconPickerInsert alt_font symbols nerd_font emoji<cr>')
end,
})
end
-62
View File
@@ -1,62 +0,0 @@
return function(use)
use {
'navarasu/onedark.nvim',
config = function()
require 'onedark'.setup { style = 'darker' }
require 'onedark'.load()
package.loaded['config.theme'] = nil
require 'config.theme'
end
}
use {
'norcalli/nvim-colorizer.lua',
config = function()
if vim.o.termguicolors then
require 'colorizer'.setup()
end
end
}
use {
'nvim-lualine/lualine.nvim',
requires = { 'kyazdani42/nvim-web-devicons', opt = true },
config = function()
require 'lualine'.setup {}
-- refresh bar when cursor moved to update line & col
local cb = function()
require 'lualine'.refresh {
scope = 'window',
place = { 'statusline' },
}
end
--[[local group = vim.api.nvim_create_augroup('lualine', {})
vim.api.nvim_create_autocmd('CursorMoved', {
group = group,
callback = cb
})]]
end
}
use {
'lewis6991/gitsigns.nvim',
config = function() require 'gitsigns'.setup() end
}
use {
'nvim-treesitter/nvim-treesitter',
run = function()
require 'nvim-treesitter.install'.update {
with_sync = true
}
end,
config = function()
require 'nvim-treesitter.configs'.setup {
ensure_installed = {"norg"},
highlight = { enable = true }
}
end,
}
use {
'elkowar/yuck.vim'
}
use {
'kmonad/kmonad-vim'
}
end
+7 -9
View File
@@ -1,17 +1,15 @@
local u = require 'config.utils' local g = vim.api.nvim_create_augroup("preview", {})
local g = vim.api.nvim_create_augroup('preview', {}) vim.api.nvim_create_autocmd("BufWritePost", {
vim.api.nvim_create_autocmd('BufWritePost', {
group = g, group = g,
pattern = '*.tex', pattern = "*.tex",
callback = function(arg) callback = function(arg)
local dir = arg.file:match('.*/') local dir = arg.file:match(".*/")
local args = '' local args = ""
if dir ~= nil then if dir ~= nil then
args = '-output-directory=\''..dir..'\' ' args = "-output-directory='"..dir.."' "
end end
vim.cmd('silent exec "!pdflatex '..args..'\''..arg.file..'\'"') vim.cmd("silent exec \"!pdflatex "..args.."'"..arg.file.."'\"")
end end
}) })
+10 -20
View File
@@ -1,28 +1,18 @@
local u = require 'config.utils'.load local u = require "config.utils".load
local g = vim.api.nvim_create_augroup('reload', {}) local g = vim.api.nvim_create_augroup("reload", {})
-- reload these files when written to -- reload these files when written to
for _, mod in ipairs({ for _, mod in ipairs({
'reload', "reload",
'settings', "settings",
'mappings', "mappings",
'utils', "utils",
'neovide', "neovide",
'theme', "theme",
'preview', "preview",
}) do u.mod_post_write(g, 'config.' .. mod, u.reload) end }) do u.mod_post_write(g, "config." .. mod, u.reload) end
-- reload plugin files when written to -- reload plugin files when written to
u.mod_post_write(g, 'config.plugins', function(mod)
u.reload(mod)
require 'packer'.compile()
end)
u.mod_post_write(g, 'config.plugins.*', function(mod)
print(mod)
u.unload(mod)
u.reload('config.plugins')
require 'packer'.compile()
end)
+8 -9
View File
@@ -5,19 +5,19 @@ local g = vim.g
o.number = true o.number = true
o.relativenumber = true o.relativenumber = true
o.showmode = false o.showmode = false
o.clipboard = 'unnamedplus' o.clipboard = "unnamedplus"
g.mapleader = ' ' g.mapleader = " "
vim.cmd('filetype plugin on') vim.cmd("filetype plugin on")
vim.cmd('syntax on') vim.cmd("syntax on")
-- line break (wrapping) settings -- line break (wrapping) settings
o.linebreak = true o.linebreak = true
o.breakindent = true o.breakindent = true
o.showbreak = '\\ ' o.showbreak = "\\ "
-- lines after end of file empty instead of ~ (fillchars) -- lines after end of file empty instead of ~ (fillchars)
o.fcs = 'eob: ' o.fcs = "eob: "
-- tab -- tab
o.expandtab = true o.expandtab = true
@@ -25,7 +25,7 @@ o.softtabstop = 4
o.shiftwidth = 4 o.shiftwidth = 4
-- turn of gui colors if in tty -- turn of gui colors if in tty
if os.getenv('TERM') ~= 'linux' then if os.getenv("TERM") ~= "linux" then
o.termguicolors = true o.termguicolors = true
else else
o.termguicolors = false o.termguicolors = false
@@ -39,6 +39,5 @@ for type, icon in pairs(signs) do
end end
vim.diagnostic.config({ vim.diagnostic.config({
virtual_text = { prefix = '' }; virtual_text = { prefix = "" },
}) })
+7 -7
View File
@@ -6,14 +6,14 @@ local gbhl = function(name, color)
end end
-- highlight extra white space with red -- highlight extra white space with red
hl('ExtraWhitespace', { ctermbg = 'red', bg = '#ff8888' }) hl("ExtraWhitespace", { ctermbg = "red", bg = "#ff8888" })
vim.cmd [[match ExtraWhitespace /\s\+$/]] vim.cmd [[match ExtraWhitespace /\s\+$/]]
-- make background transparent -- make background transparent
gbhl('Normal', 'none') gbhl("Normal", "none")
gbhl('EndOfBuffer', 'none') gbhl("EndOfBuffer", "none")
gbhl('SignColumn', 'none') gbhl("SignColumn", "none")
gbhl('NeoTreeNormal', 'none') gbhl("NeoTreeNormal", "none")
gbhl('NeoTreeNormalNC', 'none') gbhl("NeoTreeNormalNC", "none")
gbhl('NeoTreeEndOfBuffer', 'none') gbhl("NeoTreeEndOfBuffer", "none")
+9 -9
View File
@@ -3,16 +3,16 @@ local opts = { noremap = true, silent = true }
-- mapping -- mapping
local mapping = {} local mapping = {}
mapping.map = function(mode, from, to) vim.keymap.set(mode, from, to, opts) end mapping.map = function(mode, from, to) vim.keymap.set(mode, from, to, opts) end
mapping.nmap = function(from, to) vim.keymap.set('n', from, to, opts) end mapping.nmap = function(from, to) vim.keymap.set("n", from, to, opts) end
mapping.cmd = function(from, content) mapping.cmd = function(from, content)
vim.keymap.set('n', from, '<cmd>' .. content .. '<cr>', opts) vim.keymap.set("n", from, "<cmd>" .. content .. "<cr>", opts)
end end
-- layout (mapping) -- layout (mapping)
local layout = {} local layout = {}
layout.map = function(from, to) layout.map = function(from, to)
vim.keymap.set('n', from, to, opts) vim.keymap.set("n", from, to, opts)
vim.keymap.set('x', from, to, opts) vim.keymap.set("x", from, to, opts)
end end
layout.swap = function(a, b) layout.swap = function(a, b)
layout.map(a, b) layout.map(a, b)
@@ -22,10 +22,10 @@ mapping.layout = layout
-- loading stuff -- loading stuff
local load = {} local load = {}
load.lua_path = vim.fn.stdpath('config') .. '/lua/' load.lua_path = vim.fn.stdpath("config") .. "/lua/"
load.post_write = function(group, path, fn) load.post_write = function(group, path, fn)
vim.api.nvim_create_autocmd('BufWritePost', { vim.api.nvim_create_autocmd("BufWritePost", {
group = group, group = group,
pattern = load.lua_path .. path, pattern = load.lua_path .. path,
callback = fn, callback = fn,
@@ -33,12 +33,12 @@ load.post_write = function(group, path, fn)
end end
load.mod_post_write = function(group, mod, fn) load.mod_post_write = function(group, mod, fn)
local set_name = false local set_name = false
if mod:sub(-1, -1) == '*' then set_name = true end if mod:sub(-1, -1) == "*" then set_name = true end
local path = mod:gsub('[.]', '/') .. '.lua' local path = mod:gsub("[.]", "/") .. ".lua"
load.post_write(group, path, function(arg) load.post_write(group, path, function(arg)
local m = mod local m = mod
if set_name then if set_name then
local name = arg.file:match('.*/(.*).lua') local name = arg.file:match(".*/(.*).lua")
m = mod:sub(0, -2) .. name m = mod:sub(0, -2) .. name
end end
fn(m, arg) fn(m, arg)
+39
View File
@@ -0,0 +1,39 @@
local config = function()
local cmp = require("cmp")
cmp.setup({
snippet = {
expand = function(args)
require("luasnip").lsp_expand(args.body)
end
},
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-e>"] = cmp.mapping.abort(),
["<cr>"] = cmp.mapping.confirm({ select = true }),
["<tab>"] = cmp.mapping.select_next_item(),
}),
sources = cmp.config.sources({
{ name = "nvim_lsp" },
{ name = "luasnip" },
{ name = "path" },
{ name = "neorg" },
}),
})
end
return {
{
"hrsh7th/nvim-cmp",
config = config,
dependencies = {
"hrsh7th/cmp-nvim-lsp",
"hrsh7th/cmp-buffer",
"hrsh7th/cmp-path",
"hrsh7th/cmp-cmdline",
}
},
"L3MON4D3/LuaSnip",
"saadparwaiz1/cmp_luasnip",
}
@@ -1,15 +1,15 @@
local config = function() local config = function()
local settings = require 'config.lsp-settings' local settings = require("config.lsp-settings")
local on_attach = settings.on_attach local on_attach = settings.on_attach
local capabilities = settings.capabilities local capabilities = settings.capabilities
require 'lspconfig'.lua_ls.setup { require("lspconfig").lua_ls.setup {
on_attach = on_attach, on_attach = on_attach,
capabilities = capabilities, capabilities = capabilities,
settings = { settings = {
Lua = { Lua = {
diagnostics = { diagnostics = {
globals = { 'vim' }, globals = { "vim" },
}, },
workspace = { workspace = {
library = vim.api.nvim_get_runtime_file("", true), library = vim.api.nvim_get_runtime_file("", true),
@@ -22,57 +22,64 @@ local config = function()
}, },
} }
require 'rust-tools'.setup {
server = {
on_attach = on_attach,
capabilities = capabilities,
}
}
vim.g.markdown_fenced_languages = { vim.g.markdown_fenced_languages = {
"ts=typescript" "ts=typescript"
} }
require 'lspconfig'.denols.setup { require("lspconfig").denols.setup {
on_attach = on_attach, on_attach = on_attach,
capabilities = capabilities, capabilities = capabilities,
} }
require 'lspconfig'.clangd.setup { require("lspconfig").clangd.setup {
on_attach = on_attach, on_attach = on_attach,
capabilities = capabilities, capabilities = capabilities,
} }
require 'lspconfig'.asm_lsp.setup { require("lspconfig").asm_lsp.setup {
on_attach = on_attach, on_attach = on_attach,
capabilities = capabilities, capabilities = capabilities,
} }
require 'lspconfig'.pylsp.setup { require("lspconfig").pylsp.setup {
on_attach = on_attach, on_attach = on_attach,
capabilities = capabilities, capabilities = capabilities,
} }
require'lspconfig'.kotlin_language_server.setup { require("lspconfig").kotlin_language_server.setup {
on_attach = on_attach, on_attach = on_attach,
capabilities = capabilities capabilities = capabilities
} }
end end
return function(use) local rs_config = function()
use { local settings = require "config.lsp-settings"
'neovim/nvim-lspconfig', local on_attach = settings.on_attach
config = config local capabilities = settings.capabilities
} require "rust-tools".setup {
use { server = {
'simrat39/rust-tools.nvim', on_attach = on_attach,
requires = { capabilities = capabilities,
'nvim-lua/plenary.nvim',
'mfussenegger/nvim-dap',
} }
} }
use {
'windwp/nvim-autopairs',
config = function() require 'nvim-autopairs'.setup {} end
}
use {
'scalameta/nvim-metals',
requires = { "nvim-lua/plenary.nvim" }
}
use 'mfussenegger/nvim-jdtls'
end end
return {
{
"neovim/nvim-lspconfig",
config = config
},
{
"simrat39/rust-tools.nvim",
dependencies = {
"nvim-lua/plenary.nvim",
"mfussenegger/nvim-dap",
},
rs_config = rs_config
},
{
"windwp/nvim-autopairs",
config = function() require "nvim-autopairs".setup {} end
},
{
"scalameta/nvim-metals",
dependencies = { "nvim-lua/plenary.nvim" }
},
"mfussenegger/nvim-jdtls",
"folke/neodev.nvim"
}
+38
View File
@@ -0,0 +1,38 @@
return {
{
"nvim-telescope/telescope.nvim",
tag = "0.1.0",
dependencies = { "nvim-lua/plenary.nvim" },
config = function()
require("telescope").setup {}
local u = require("config.utils").mapping
u.cmd("<leader>ff", "Telescope find_files")
u.cmd("<leader>fg", "Telescope live_grep")
u.cmd("<leader>fb", "Telescope buffers")
u.cmd("<leader>fh", "Telescope help_tags")
end
},
{
"nvim-telescope/telescope-fzf-native.nvim",
build = "make",
dependencies = { "nvim-telescope/telescope.nvim" },
config = function() require("telescope").load_extension("fzf") end
},
{
"nvim-telescope/telescope-ui-select.nvim",
dependencies = { "nvim-telescope/telescope.nvim" },
config = function() require("telescope").load_extension("ui-select") end
},
{
"ziontee113/icon-picker.nvim",
dependencies = { "stevearc/dressing.nvim" },
config = function()
require("icon-picker").setup {}
local u = require("config.utils").mapping
u.cmd("<leader>fi", "IconPickerYank alt_font symbols nerd_font emoji")
vim.keymap.set("i", "<c-s>", "<cmd>IconPickerInsert alt_font symbols nerd_font emoji<cr>")
end,
}
}
@@ -1,15 +1,15 @@
return function(use) return {
use { {
'nvim-neo-tree/neo-tree.nvim', 'nvim-neo-tree/neo-tree.nvim',
branch = "v2.x", branch = "v2.x",
requires = { dependencies = {
'nvim-lua/plenary.nvim', 'nvim-lua/plenary.nvim',
'kyazdani42/nvim-web-devicons', 'kyazdani42/nvim-web-devicons',
'MunifTanjim/nui.nvim' 'MunifTanjim/nui.nvim'
}, },
config = function() config = function()
vim.cmd [[ let g:neo_tree_remove_legacy_commands = 1 ]] vim.cmd [[ let g:neo_tree_remove_legacy_commands = 1 ]]
require 'neo-tree'.setup { require('neo-tree').setup {
close_if_last_window = true, close_if_last_window = true,
filesystem = { filesystem = {
filtered_items = { filtered_items = {
@@ -29,4 +29,4 @@ return function(use)
u.cmd('<leader>e', 'Neotree toggle') u.cmd('<leader>e', 'Neotree toggle')
end end
} }
end }
@@ -1,5 +1,5 @@
return function(use) return {
use { {
'nvim-neorg/neorg', 'nvim-neorg/neorg',
tag = '0.0.12', tag = '0.0.12',
config = function() config = function()
@@ -16,16 +16,6 @@ return function(use)
} }
} }
end, end,
requires = 'nvim-lua/plenary.nvim' dependencies = 'nvim-lua/plenary.nvim'
},
} }
use({
"iamcco/markdown-preview.nvim",
run = function() vim.fn["mkdp#util#install"]() end,
})
vim.cmd([[
function! OpenMarkdownPreview (url)
execute "silent ! firefox --new-window " . a:url
endfunction
let g:mkdp_browserfunc = 'OpenMarkdownPreview'
]])
end
+46
View File
@@ -0,0 +1,46 @@
return {
{
"navarasu/onedark.nvim",
config = function()
require("onedark").setup { style = "darker" }
require("onedark").load()
package.loaded["config.theme"] = nil
require("config.theme")
end
},
{
"norcalli/nvim-colorizer.lua",
config = function()
if vim.o.termguicolors then
require("colorizer").setup()
end
end
},
{
"nvim-lualine/lualine.nvim",
dependencies = { "kyazdani42/nvim-web-devicons" },
config = function()
require("lualine").setup {}
end
},
{
"lewis6991/gitsigns.nvim",
config = function() require("gitsigns").setup() end
},
{
"nvim-treesitter/nvim-treesitter",
build = function()
require("nvim-treesitter.install").update {
with_sync = true
}
end,
config = function()
require("nvim-treesitter.configs").setup {
ensure_installed = { "norg" },
highlight = { enable = true }
}
end,
},
"elkowar/yuck.vim",
"kmonad/kmonad-vim"
}