Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add telescope integration #4

Merged
merged 6 commits into from
Oct 28, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Simplify window ID cleanup
  • Loading branch information
EvWilson committed Oct 28, 2024
commit 751c81e27ead220f434d0d626ebd4ad61395b2ca
5 changes: 2 additions & 3 deletions lua/spelunk/ui.lua
Original file line number Diff line number Diff line change
Expand Up @@ -219,15 +219,15 @@ function M.create_windows()
focus_cb, unfocus_cb = persist_focus(win_id, function()
if window_ready(window_id) then
vim.api.nvim_win_close(window_id, true)
window_id = -1
end
window_id = -1
-- Defer preview window cleanup, as running it concurrently to main window
-- causes it to not fire
vim.schedule(function()
if window_ready(preview_window_id) then
vim.api.nvim_win_close(preview_window_id, true)
preview_window_id = -1
end
preview_window_id = -1
end)
end)

Expand Down Expand Up @@ -294,7 +294,6 @@ end
function M.close_windows()
if window_ready(window_id) then
vim.api.nvim_win_close(window_id, true)
window_id = -1
end
end

Expand Down