vim: only execute config if respective plugin is installed
This commit is contained in:
parent
ca271dd50c
commit
9011cadd56
5 changed files with 18 additions and 4 deletions
|
@ -1,4 +1,7 @@
|
|||
require('indent_blankline').setup {
|
||||
local ok, plugin = pcall(require, 'indent_blankline')
|
||||
if not ok then return end
|
||||
|
||||
plugin.setup {
|
||||
enabled = false,
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,7 @@
|
|||
require('nvim-tree').setup {
|
||||
local ok, plugin = pcall(require, 'nvim-tree')
|
||||
if not ok then return end
|
||||
|
||||
plugin.setup {
|
||||
git = {
|
||||
ignore = false, -- don't hide files from .gitignore
|
||||
},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
if not vim.fn.exists('g:tabular_loaded') then return end
|
||||
|
||||
vim.cmd [[ AddTabularPattern! first_comma /^[^,]*\zs,/ ]]
|
||||
vim.cmd [[ AddTabularPattern! first_colon /^[^:]*\zs:/ ]]
|
||||
vim.cmd [[ AddTabularPattern! first_equal /^[^=]*\zs=/ ]]
|
||||
|
|
|
@ -1,3 +1,6 @@
|
|||
local ok, telescope = pcall(require, 'telescope')
|
||||
if not ok then return end
|
||||
|
||||
local actions = require 'telescope.actions'
|
||||
local builtin = require 'telescope.builtin'
|
||||
|
||||
|
@ -50,7 +53,7 @@ local find_options = function()
|
|||
}
|
||||
end
|
||||
|
||||
require('telescope').setup {
|
||||
telescope.setup {
|
||||
defaults = {
|
||||
prompt_prefix = '❯ ',
|
||||
selection_caret = '➔ ',
|
||||
|
|
|
@ -1,4 +1,7 @@
|
|||
require('virt-column').setup {
|
||||
local ok, plugin = pcall(require, 'virt-column')
|
||||
if not ok then return end
|
||||
|
||||
plugin.setup {
|
||||
char = '│',
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue