feat(tabs): add tab.sync options (#1698)

* Sync closing of nvim-tree across tabs

* chore: remove vim.* "requires"

* Sync closing of nvim-tree across tabs

* Fix api.close calls

* Fix issue from merge

* Implement changes

* Finish todos and add close_all_tabs

* silently refactor options, add doc

* fix vinegar example

* Refactor close to work with tabid

* Close nvim tree if last buffer

* close and abandon all tabs on subsequent setup calls

Co-authored-by: Alexander Courtis <alex@courtis.org>
This commit is contained in:
Wessel Blokzijl
2022-11-19 03:57:45 +01:00
committed by GitHub
parent 1837751efb
commit c49499413a
7 changed files with 120 additions and 43 deletions

View File

@@ -117,7 +117,7 @@ function M.open(cwd)
core.init(cwd or vim.loop.cwd())
end
if should_hijack_current_buf() then
view.close()
view.close_this_tab_only()
view.open_in_current_win()
renderer.draw()
else