Fix version of nightfox for nvim<=0.7

Move LSP config into config_plugins directory, function when loading
nvim-lspconfig plugin
This commit is contained in:
Evie Litherland-Smith 2022-11-28 13:25:36 +00:00
parent 820e8488cc
commit 8c16cb127c
3 changed files with 25 additions and 14 deletions

View file

@ -7,8 +7,5 @@ require 'plugins'
-- Define custom keymappings
require 'keymaps'
-- Setup LSP configuration
require 'config_lsp'
-- Remaining vim commands to be converted to lua
require 'vimcommands'

View file

@ -8,8 +8,8 @@ vim.keymap.set('n', '<leader>q', vim.diagnostic.setloclist, opts)
local signs = { Error = "", Warn = "", Hint = "", Info = "" }
for type, icon in pairs(signs) do
local hl = "DiagnosticSign" .. type
vim.fn.sign_define(hl, { text = icon, texthl = hl, numhl = hl })
local hl = "DiagnosticSign" .. type
vim.fn.sign_define(hl, { text = icon, texthl = hl, numhl = hl })
end
-- Use an on_attach function to only map the following keys

View file

@ -5,6 +5,12 @@ vim.cmd([[
augroup end
]])
if vim.version().minor <= 7 then
NIGHTFOXVERSION = '15f3b5837a8d07f45cbe16753fbf13630bc167a3'
else
NIGHTFOXVERSION = '*'
end
require('packer').startup {
function(use)
use 'wbthomason/packer.nvim'
@ -16,18 +22,26 @@ require('packer').startup {
}
use 'kyazdani42/nvim-web-devicons'
use 'nvim-lua/plenary.nvim'
use {
'neovim/nvim-lspconfig',
config = function()
require 'config_plugins.config_lsp'
end,
}
use 'christoomey/vim-tmux-navigator'
use 'neovim/nvim-lspconfig'
use 'hrsh7th/cmp-nvim-lsp'
use 'hrsh7th/cmp-buffer'
use 'hrsh7th/cmp-path'
use 'hrsh7th/cmp-cmdline'
use 'hrsh7th/cmp-nvim-lua'
use 'hrsh7th/nvim-cmp'
use 'hrsh7th/cmp-vsnip'
use 'hrsh7th/vim-vsnip'
use {
'hrsh7th/cmp-nvim-lsp',
'hrsh7th/cmp-buffer',
'hrsh7th/cmp-path',
'hrsh7th/cmp-cmdline',
'hrsh7th/cmp-nvim-lua',
'hrsh7th/nvim-cmp',
'hrsh7th/cmp-vsnip',
'hrsh7th/vim-vsnip',
}
use {
'EdenEast/nightfox.nvim',
tag = NIGHTFOXVERSION,
config = function()
require 'config_plugins.config_nightfox'
end