Skip to content

Commit

Permalink
feat(pack): add ProtoBuf pack (#330)
Browse files Browse the repository at this point in the history
Signed-off-by: Miguel Casqueira <[email protected]>
Co-authored-by: Miguel Casqueira <[email protected]>
  • Loading branch information
2 people authored and mehalter committed Jun 29, 2023
1 parent 8de68ab commit bafa6dc
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 0 deletions.
7 changes: 7 additions & 0 deletions lua/astrocommunity/pack/proto/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Protocal Buffers Pack

This plugin pack does the following:

- Adds `proto` Treesitter parsers
- Adds `bufls` language servers
- Adds `buf` formatter
20 changes: 20 additions & 0 deletions lua/astrocommunity/pack/proto/init.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
local utils = require "astronvim.utils"
return {
{
"nvim-treesitter/nvim-treesitter",
opts = function(_, opts)
-- Ensure that opts.ensure_installed exists and is a table or string "all".
if opts.ensure_installed ~= "all" then
opts.ensure_installed = utils.list_insert_unique(opts.ensure_installed, "proto")
end
end,
},
{
"williamboman/mason-lspconfig.nvim",
opts = function(_, opts) opts.ensure_installed = utils.list_insert_unique(opts.ensure_installed, "bufls") end,
},
{
"jay-babu/mason-null-ls.nvim",
opts = function(_, opts) opts.ensure_installed = utils.list_insert_unique(opts.ensure_installed, "buf") end,
},
}

0 comments on commit bafa6dc

Please sign in to comment.