nvim: move to lazy.nvim
This commit is contained in:
parent
a6f429aa5d
commit
dc218d6736
3 changed files with 30 additions and 47 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -2,4 +2,4 @@ cli/.config/zsh/env.zsh
|
|||
cli/.config/zsh/local.zsh
|
||||
cli/.config/fish/conf.d/local.fish
|
||||
cli/.config/fish/fish_variables
|
||||
cli/.config/nvim/plugin/packer_compiled.lua
|
||||
cli/.config/nvim/lazy-lock.json
|
||||
|
|
|
@ -1,23 +0,0 @@
|
|||
local packer_init = {}
|
||||
|
||||
packer_init.init = function(plugins)
|
||||
local ensure_packer = function()
|
||||
local install_path = vim.fn.stdpath('data')..'/site/pack/packer/start/packer.nvim'
|
||||
if vim.fn.empty(vim.fn.glob(install_path)) > 0 then
|
||||
vim.fn.system {'git', 'clone', '--depth', '1', 'https://github.com/wbthomason/packer.nvim', install_path}
|
||||
vim.cmd [[packadd packer.nvim]]
|
||||
return true
|
||||
end
|
||||
return false
|
||||
end
|
||||
|
||||
local packer_bootstrap = ensure_packer()
|
||||
require('packer').startup(plugins)
|
||||
if packer_bootstrap then
|
||||
require('packer').sync()
|
||||
return true
|
||||
end
|
||||
return false
|
||||
end
|
||||
|
||||
return packer_init
|
|
@ -1,28 +1,34 @@
|
|||
-- [[ plugins list ]]
|
||||
local function plugins(use)
|
||||
use 'wbthomason/packer.nvim'
|
||||
|
||||
use {
|
||||
'lifepillar/vim-solarized8',
|
||||
branch = 'neovim'
|
||||
}
|
||||
use 'lifepillar/vim-cheat40'
|
||||
use 'hashivim/vim-terraform'
|
||||
use 'khaveesh/vim-fish-syntax'
|
||||
use 'lewis6991/gitsigns.nvim'
|
||||
use 'tpope/vim-rsi'
|
||||
use 'tpope/vim-vinegar'
|
||||
use {
|
||||
'nvim-telescope/telescope.nvim',
|
||||
requires = 'nvim-lua/plenary.nvim'
|
||||
}
|
||||
use {
|
||||
'w0rp/ale',
|
||||
ft = { 'bash', 'sh', 'zsh', 'lua', 'python' },
|
||||
cmd = 'ALEEnable'
|
||||
-- [[ plugins bootstrap ]]
|
||||
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", lazypath
|
||||
}
|
||||
end
|
||||
if require('packer_init').init(plugins) then return end
|
||||
vim.opt.rtp:prepend(lazypath)
|
||||
|
||||
--[[ plugins list ]]
|
||||
require('lazy').setup {
|
||||
{'lifepillar/vim-solarized8', branch = 'neovim'},
|
||||
'lewis6991/gitsigns.nvim',
|
||||
'lifepillar/vim-cheat40',
|
||||
'hashivim/vim-terraform',
|
||||
'khaveesh/vim-fish-syntax',
|
||||
'lewis6991/gitsigns.nvim',
|
||||
'tpope/vim-rsi',
|
||||
'tpope/vim-vinegar',
|
||||
{
|
||||
'nvim-telescope/telescope.nvim',
|
||||
dependencies = {'nvim-lua/plenary.nvim'}
|
||||
},
|
||||
{
|
||||
'w0rp/ale',
|
||||
cmd = 'ALEEnable',
|
||||
ft = {'bash', 'sh', 'zsh', 'lua', 'python'}
|
||||
}
|
||||
}
|
||||
|
||||
--[[ plugin configs and maps ]]
|
||||
require('gitsigns').setup()
|
||||
|
|
Loading…
Reference in a new issue