mirror of
https://github.com/Baipyrus/nvim-config.git
synced 2024-12-27 05:41:45 +00:00
Compare commits
No commits in common. "5ad7502e8808fcd89e8c2c4af959d9d5cbc4a21b" and "811f2c71d9bbbbd51c65ab2da2065566c84c6518" have entirely different histories.
5ad7502e88
...
811f2c71d9
@ -1,8 +1,8 @@
|
||||
-- [[ Basic Keymaps ]]
|
||||
-- See `:help vim.keymap.set()`
|
||||
|
||||
-- Clear highlights on search when pressing <Esc> in normal mode
|
||||
-- See `:help hlsearch`
|
||||
-- Set highlight on search, but clear on pressing <Esc> in normal mode
|
||||
vim.opt.hlsearch = true
|
||||
vim.keymap.set('n', '<Esc>', '<cmd>nohlsearch<CR>')
|
||||
|
||||
-- Diagnostic keymaps
|
||||
|
@ -30,8 +30,9 @@ return {
|
||||
-- Conform can also run multiple formatters sequentially
|
||||
python = { 'isort', 'black' },
|
||||
|
||||
-- You can use 'stop_after_first' to run the first available formatter from the list
|
||||
javascript = { 'prettierd', 'prettier', stop_after_first = true },
|
||||
-- You can use a sub-list to tell conform to run *until* a formatter
|
||||
-- is found.
|
||||
javascript = { { 'prettierd', 'prettier' } },
|
||||
},
|
||||
},
|
||||
},
|
||||
|
@ -1,20 +1,5 @@
|
||||
-- LSP Plugins
|
||||
return {
|
||||
{
|
||||
-- `lazydev` configures Lua LSP for your Neovim config, runtime and plugins
|
||||
-- used for completion, annotations and signatures of Neovim apis
|
||||
'folke/lazydev.nvim',
|
||||
ft = 'lua',
|
||||
opts = {
|
||||
library = {
|
||||
-- Load luvit types when the `vim.uv` word is found
|
||||
{ path = 'luvit-meta/library', words = { 'vim%.uv' } },
|
||||
},
|
||||
},
|
||||
},
|
||||
{ 'Bilal2453/luvit-meta', lazy = true },
|
||||
{
|
||||
-- Main LSP Configuration
|
||||
{ -- LSP Configuration & Plugins
|
||||
'neovim/nvim-lspconfig',
|
||||
dependencies = {
|
||||
-- Automatically install LSPs and related tools to stdpath for Neovim
|
||||
@ -25,6 +10,20 @@ return {
|
||||
-- Useful status updates for LSP.
|
||||
-- NOTE: `opts = {}` is the same as calling `require('fidget').setup({})`
|
||||
{ 'j-hui/fidget.nvim', opts = {} },
|
||||
|
||||
-- `lazydev` configures Lua LSP for your Neovim config, runtime and plugins
|
||||
-- used for completion, annotations and signatures of Neovim apis
|
||||
{
|
||||
'folke/lazydev.nvim',
|
||||
ft = 'lua',
|
||||
opts = {
|
||||
library = {
|
||||
-- Load luvit types when the `vim.uv` word is found
|
||||
{ path = 'luvit-meta/library', words = { 'vim%.uv' } },
|
||||
},
|
||||
},
|
||||
},
|
||||
{ 'Bilal2453/luvit-meta', lazy = true },
|
||||
},
|
||||
config = function()
|
||||
-- Brief aside: **What is LSP?**
|
||||
|
@ -38,12 +38,9 @@ vim.opt.mouse = 'a'
|
||||
vim.opt.showmode = false
|
||||
|
||||
-- Sync clipboard between OS and Neovim.
|
||||
-- Schedule the setting after `UiEnter` because it can increase startup-time.
|
||||
-- Remove this option if you want your OS clipboard to remain independent.
|
||||
-- See `:help 'clipboard'`
|
||||
vim.schedule(function()
|
||||
vim.opt.clipboard = 'unnamedplus'
|
||||
end)
|
||||
|
||||
-- Enable break indent
|
||||
vim.opt.breakindent = true
|
||||
@ -92,9 +89,6 @@ vim.opt.sidescrolloff = 12
|
||||
-- Set cursor pointer to block
|
||||
vim.opt.guicursor = 'n-v-i-c:block-Cursor'
|
||||
|
||||
vim.api.nvim_create_autocmd('UIEnter', {
|
||||
group = vim.api.nvim_create_augroup('SetGUISettings', { clear = true }),
|
||||
callback = function()
|
||||
-- Options specifically targeted at Neovide
|
||||
if vim.g.neovide then
|
||||
vim.o.guifont = 'CaskaydiaCove Nerd Font Mono:h14'
|
||||
@ -102,7 +96,5 @@ vim.api.nvim_create_autocmd('UIEnter', {
|
||||
vim.g.neovide_cursor_animation_length = 0
|
||||
vim.g.neovide_cursor_trail_length = 0
|
||||
end
|
||||
end,
|
||||
})
|
||||
|
||||
-- vim: ts=2 sts=2 sw=2 et
|
||||
|
Loading…
Reference in New Issue
Block a user