require('plugin') -- packer plugin-manager
local plugins = {
'cmp', -- lsp setup
'mason', -- lsp installer
'mason.tools', -- auto lsp installer
'symbols-outline', -- symbols
'colorizer', -- render colors
'lualine', -- status line
'treesitter', -- treesitter settings
'which-key', -- show keybinds
'gitsigns', -- show `git diff` in line-number
'telescope', -- Telescope
'undotree', -- undotree
'venn', -- draw ascii diagram
'truezen', -- zen-mode: focus
'autopairs',
-- tmp {{{
-- 'lsp', -- lsp usage configs
-- 'null-ls', -- null-ls
-- 'cmp.bashls',
-- 'cmp.clangd',
-- 'cmp.gopls',
-- 'cmp.html-css',
-- 'cmp.lua_ls',
-- 'cmp.pyright',
-- 'cmp.texlab',
-- 'nvimtree', -- nvim-tree
-- 'toggleterm', -- ToggleTerm
-- 'alpha', -- greetings at empty buffers
-- 'comment', -- comment handler config
---- these modules are in `lua/module/.tmp/`
-- 'trouble', -- debug adapter protocol
-- 'harpoon', -- new filebuffer
-- 'git-worktree', -- git worktree
-- 'neotree', -- NeoTree
-- 'notify', -- notification manager
-- }}}
}
local function plugthem(pluglist)
for _,name in ipairs(pluglist) do
local plugname = 'plugin.'..name
local stat = pcall(require, plugname)
if stat == false then
vim.notify(name..' is not installed or has a syntax error',
3, {title = 'plugthem()'})
-- vim.cmd ':PackerInstall'{{{
-- if name == 'mason' then
-- vim.cmd ':MasonUpdate'
-- elseif name == 'treesitter' then
-- vim.cmd ':TSUpdate'
-- end}}}
else
require(plugname)
end
end
end
plugthem(plugins)
{"html5":"htmlmixed","css":"css","javascript":"javascript","php":"php","python":"python","ruby":"ruby","lua":"text\/x-lua","bash":"text\/x-sh","go":"go","c":"text\/x-csrc","cpp":"text\/x-c++src","diff":"diff","latex":"stex","sql":"sql","xml":"xml","apl":"apl","asterisk":"asterisk","c_loadrunner":"text\/x-csrc","c_mac":"text\/x-csrc","coffeescript":"text\/x-coffeescript","csharp":"text\/x-csharp","d":"d","ecmascript":"javascript","erlang":"erlang","groovy":"text\/x-groovy","haskell":"text\/x-haskell","haxe":"text\/x-haxe","html4strict":"htmlmixed","java":"text\/x-java","java5":"text\/x-java","jquery":"javascript","mirc":"mirc","mysql":"sql","ocaml":"text\/x-ocaml","pascal":"text\/x-pascal","perl":"perl","perl6":"perl","plsql":"sql","properties":"text\/x-properties","q":"text\/x-q","scala":"scala","scheme":"text\/x-scheme","tcl":"text\/x-tcl","vb":"text\/x-vb","verilog":"text\/x-verilog","yaml":"text\/x-yaml","z80":"text\/x-z80"}