@@ -517,7 +517,11 @@ M.refresh = function(source_name, callback)
517517 end
518518end
519519
520+ --- DEPRECATED: To be removed in 4.0
521+ --- use `require("neo-tree.command").execute({ source_name = source_name, action = "focus", reveal = true })` instead
520522M .reveal_current_file = function (source_name , callback , force_cwd )
523+ log .warn ([[ DEPRECATED: use `require("neo-tree.command").execute({ source_name = source_name, action = "focus", reveal = true })` instead]] )
524+
521525 log .trace (" Revealing current file" )
522526 local state = M .get_state (source_name )
523527 state .current_position = nil
@@ -527,7 +531,6 @@ M.reveal_current_file = function(source_name, callback, force_cwd)
527531 -- (potentially) different position/node
528532 state .position .is .restorable = false
529533
530- require (" neo-tree" ).close_all_except (source_name )
531534 local path = M .get_path_to_reveal ()
532535 if not path then
533536 M .focus (source_name )
@@ -560,7 +563,11 @@ M.reveal_current_file = function(source_name, callback, force_cwd)
560563 end
561564end
562565
566+ --- DEPRECATED: To be removed in 4.0
567+ --- use `require("neo-tree.command").execute({ source_name = source_name, action = "focus", reveal = true, position = "current" })` instead
563568M .reveal_in_split = function (source_name , callback )
569+ log .warn ([[ DEPRECATED: use `require("neo-tree.command").execute({ source_name = source_name, action = "focus", reveal = true, position = "current" })` instead]] )
570+
564571 local state = M .get_state (source_name , nil , vim .api .nvim_get_current_win ())
565572 state .current_position = " current"
566573 local path_to_reveal = M .get_path_to_reveal ()
0 commit comments