44 lines
1.0 KiB
Lua
44 lines
1.0 KiB
Lua
local execute = vim.api.nvim_command
|
|
local fn = vim.fn
|
|
-- ensure that packer is installed
|
|
local install_path = fn.stdpath("data") .. "/site/pack/packer/opt/packer.nvim"
|
|
if fn.empty(fn.glob(install_path)) > 0 then
|
|
execute("!git clone https://github.com/wbthomason/packer.nvim " .. install_path)
|
|
execute "packadd packer.nvim"
|
|
end
|
|
vim.cmd("packadd packer.nvim")
|
|
local packer = require "packer"
|
|
local util = require "packer.util"
|
|
|
|
packer.init(
|
|
{
|
|
package_root = util.join_paths(vim.fn.stdpath("data"), "site", "pack")
|
|
}
|
|
)
|
|
|
|
return require("packer").startup(
|
|
function()
|
|
-- Packer can manage itself
|
|
use "wbthomason/packer.nvim"
|
|
use {
|
|
"MasterGordon/monokai.nvim",
|
|
config = function()
|
|
require("monokai").setup()
|
|
end
|
|
}
|
|
use {
|
|
"mfussenegger/nvim-jdtls",
|
|
config = function()
|
|
vim.cmd(
|
|
[[
|
|
augroup jdtls_lsp
|
|
autocmd!
|
|
autocmd FileType java lua require'plugins/java-lsp'.setup()
|
|
augroup end
|
|
]]
|
|
)
|
|
end
|
|
}
|
|
end
|
|
)
|