Skip to content

Commit

Permalink
fix(#2114): remove deprecated non-API from lib, events (#2121)
Browse files Browse the repository at this point in the history
  • Loading branch information
alex-courtis committed Apr 11, 2023
1 parent 086bf31 commit 920d5c8
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 58 deletions.
45 changes: 0 additions & 45 deletions lua/nvim-tree/events.lua
Original file line number Diff line number Diff line change
Expand Up @@ -92,49 +92,4 @@ function M._dispatch_tree_attached_post(buf)
dispatch(M.Event.TreeAttachedPost, buf)
end

--- @deprecated
function M.on_nvim_tree_ready(handler)
M.subscribe(M.Event.Ready, handler)
end

--- @deprecated
function M.on_node_renamed(handler)
M.subscribe(M.Event.NodeRenamed, handler)
end

--- @deprecated
function M.on_file_created(handler)
M.subscribe(M.Event.FileCreated, handler)
end

--- @deprecated
function M.on_file_removed(handler)
M.subscribe(M.Event.FileRemoved, handler)
end

--- @deprecated
function M.on_folder_created(handler)
M.subscribe(M.Event.FolderCreated, handler)
end

--- @deprecated
function M.on_folder_removed(handler)
M.subscribe(M.Event.FolderRemoved, handler)
end

--- @deprecated
function M.on_tree_open(handler)
M.subscribe(M.Event.TreeOpen, handler)
end

--- @deprecated
function M.on_tree_close(handler)
M.subscribe(M.Event.TreeClose, handler)
end

--- @deprecated
function M.on_tree_resize(handler)
M.subscribe(M.Event.Resize, handler)
end

return M
13 changes: 0 additions & 13 deletions lua/nvim-tree/lib.lua
Original file line number Diff line number Diff line change
Expand Up @@ -178,19 +178,6 @@ function M.open(opts)
events._dispatch_on_tree_open()
end

-- @deprecated: use nvim-tree.actions.tree-modifiers.collapse-all.fn
M.collapse_all = require("nvim-tree.actions.tree-modifiers.collapse-all").fn
-- @deprecated: use nvim-tree.actions.root.dir-up.fn
M.dir_up = require("nvim-tree.actions.root.dir-up").fn
-- @deprecated: use nvim-tree.actions.root.change-dir.fn
M.change_dir = require("nvim-tree.actions.root.change-dir").fn
-- @deprecated: use nvim-tree.actions.reloaders.reloaders.reload_explorer
M.refresh_tree = require("nvim-tree.actions.reloaders.reloaders").reload_explorer
-- @deprecated: use nvim-tree.actions.reloaders.reloaders.reload_git
M.reload_git = require("nvim-tree.actions.reloaders.reloaders").reload_git
-- @deprecated: use nvim-tree.actions.finders.find-file.fn
M.set_index_and_redraw = require("nvim-tree.actions.finders.find-file").fn

function M.setup(opts)
M.hijack_unnamed_buffer_when_opening = opts.hijack_unnamed_buffer_when_opening
M.hijack_directories = opts.hijack_directories
Expand Down

0 comments on commit 920d5c8

Please sign in to comment.