Skip to content

Commit

Permalink
fix: fixes #9, empty highlight group errors. also add missing plugins…
Browse files Browse the repository at this point in the history
… dir
  • Loading branch information
cseickel committed Jan 3, 2022
1 parent 0c4a068 commit 844d345
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 1 deletion.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@ Example for packer:
use {
"nvim-neo-tree/neo-tree.nvim",
branch = "v1.x",
requires = { "MunifTanjim/nui.nvim" },
requires = {
"nvim-lua/plenary.nvim",
"kyazdani42/nvim-web-devicons", -- not strictly required, but recommended
"MunifTanjim/nui.nvim"
},
config = function ()
require("neo-tree").setup()
vim.cmd([[nnoremap \ :NeoTreeReveal<cr>]])
Expand Down
2 changes: 2 additions & 0 deletions lua/neo-tree/ui/highlights.lua
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,8 @@ local function create_highlight_group(hl_group_name, link_to_if_exists, backgrou
end
if foreground then
cmd = cmd .. " guifg=#" .. foreground
else
cmd = cmd .. " guifg=NONE"
end
if gui then
cmd = cmd .. " gui=" .. gui
Expand Down
9 changes: 9 additions & 0 deletions plugin/neo-tree.vim
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
if exists('g:loaded_neo_tree')
finish
endif
let g:loaded_neo_tree = 1

command! NeoTreeClose lua require("neo-tree").close()
command! NeoTreeFocus lua require("neo-tree").focus()
command! NeoTreeShow lua require("neo-tree").show(nil, true)
command! NeoTreeReveal lua require("neo-tree.sources.filesystem").reveal_current_file()

0 comments on commit 844d345

Please sign in to comment.