elixir updates

This commit is contained in:
Chris 2021-07-03 11:32:28 -04:00
parent dcdf5fd4ee
commit 98c4324084
3 changed files with 45 additions and 37 deletions

View file

@ -3,8 +3,8 @@ require'lspconfig'.elixirls.setup{
} }
-- needed for the LSP to recognize elixir files (alternativly just use elixir-editors/vim-elixir) -- needed for the LSP to recognize elixir files (alternativly just use elixir-editors/vim-elixir)
vim.cmd([[ -- vim.cmd([[
au BufRead,BufNewFile *.ex,*.exs set filetype=elixir -- au BufRead,BufNewFile *.ex,*.exs set filetype=elixir
au BufRead,BufNewFile *.eex,*.leex,*.sface set filetype=eelixir -- au BufRead,BufNewFile *.eex,*.leex,*.sface set filetype=eelixir
au BufRead,BufNewFile mix.lock set filetype=elixir -- au BufRead,BufNewFile mix.lock set filetype=elixir
]]) -- ]])

11
ftplugin/euphoria3.lua Normal file
View file

@ -0,0 +1,11 @@
-- TODO Remove this at some point
require'lspconfig'.elixirls.setup{
cmd = { DATA_PATH .. "/lspinstall/elixir/elixir-ls/language_server.sh"};
}
-- needed for the LSP to recognize elixir files (alternativly just use elixir-editors/vim-elixir)
-- vim.cmd([[
-- au BufRead,BufNewFile *.ex,*.exs set filetype=elixir
-- au BufRead,BufNewFile *.eex,*.leex,*.sface set filetype=eelixir
-- au BufRead,BufNewFile mix.lock set filetype=elixir
-- ]])

View file

@ -10,21 +10,19 @@ if fn.empty(fn.glob(install_path)) > 0 then
end end
local packer_ok, packer = pcall(require, "packer") local packer_ok, packer = pcall(require, "packer")
if not packer_ok then if not packer_ok then return end
return
end
packer.init { packer.init {
-- compile_path = vim.fn.stdpath('data')..'/site/pack/loader/start/packer.nvim/plugin/packer_compiled.vim', -- compile_path = vim.fn.stdpath('data')..'/site/pack/loader/start/packer.nvim/plugin/packer_compiled.vim',
compile_path = require("packer.util").join_paths(vim.fn.stdpath('config'), 'plugin', 'packer_compiled.vim'), compile_path = require("packer.util").join_paths(vim.fn.stdpath('config'),
git = { 'plugin',
clone_timeout = 300 'packer_compiled.vim'),
}, git = {clone_timeout = 300},
display = { display = {
open_fn = function() open_fn = function()
return require("packer.util").float {border = "single"} return require("packer.util").float {border = "single"}
end, end
}, }
} }
vim.cmd "autocmd BufWritePost plugins.lua PackerCompile" -- Auto compile when there are changes in plugins.lua vim.cmd "autocmd BufWritePost plugins.lua PackerCompile" -- Auto compile when there are changes in plugins.lua
@ -46,15 +44,15 @@ return require("packer").startup(function(use)
config = [[require('lv-telescope')]], config = [[require('lv-telescope')]],
cmd = "Telescope" cmd = "Telescope"
} }
-- Snap -- Snap TODO disable for now, need to only install fzy when user specifies they want to use snap
use { -- use {
"camspiers/snap", -- "camspiers/snap",
rocks = "fzy", -- rocks = "fzy",
config = function() -- config = function()
require("lv-snap").config() -- require("lv-snap").config()
end, -- end,
disable = not O.plugin.snap.active, -- disable = not O.plugin.snap.active
} -- }
-- Autocomplete -- Autocomplete
use { use {
"hrsh7th/nvim-compe", "hrsh7th/nvim-compe",
@ -90,8 +88,11 @@ return require("packer").startup(function(use)
use {"folke/which-key.nvim"} use {"folke/which-key.nvim"}
-- Autopairs -- Autopairs
use {"windwp/nvim-autopairs", use {
config = function() require'lv-autopairs' end "windwp/nvim-autopairs",
config = function()
require 'lv-autopairs'
end
} }
-- Comments -- Comments
@ -399,9 +400,8 @@ return require("packer").startup(function(use)
-- Lush Create Color Schemes -- Lush Create Color Schemes
use { use {
"rktjmp/lush.nvim", "rktjmp/lush.nvim",
event = "VimEnter",
-- cmd = {"LushRunQuickstart", "LushRunTutorial", "Lushify"}, -- cmd = {"LushRunQuickstart", "LushRunTutorial", "Lushify"},
-- disable = not O.plugin.lush.active, disable = not O.plugin.lush.active,
} }
-- HTML preview -- HTML preview
use { use {
@ -420,15 +420,12 @@ return require("packer").startup(function(use)
-- LANGUAGE SPECIFIC GOES HERE -- LANGUAGE SPECIFIC GOES HERE
-- Latex TODO what filetypes should this be active for? -- Latex TODO what filetypes should this be active for?
use {"lervag/vimtex", ft = "latex", disable = not O.lang.latex.active} use {"lervag/vimtex", ft = "latex"}
-- Rust tools -- Rust tools
-- TODO: use lazy loading maybe? -- TODO: use lazy loading maybe?
use {"simrat39/rust-tools.nvim", disable = not O.lang.rust.active} use {"simrat39/rust-tools.nvim", ft = "rust"}
-- Elixir -- Elixir
use {"elixir-editors/vim-elixir", use {"elixir-editors/vim-elixir", ft = {"elixir", "eelixir", "euphoria3"}}
ft = {"elixir", "eelixir"},
disable = not O.lang.elixir.active
}
end) end)