You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have something working here as also use fzf-lua and workspaces. Fzf-lua doesn't seem to have a concept of extensions like telescope but can still create custom pickers fairly easily. I took a look at todo-comments.nvim which also provides both a telescope extension and fzf helper.
Based on that I have a simple version working locally:
local M = {}
local workspaces = require("workspaces")
local fzfLua = require("fzf-lua")
function M.workspace_switch()
local opts = {}
opts.actions = {
['default'] = function(selected)
workspaces.open(selected[1])
end
}
fzfLua.fzf_exec(function(fzf_cb)
local workspace_list = workspaces.get()
for _, workspace in ipairs(workspace_list) do
fzf_cb(workspace.name)
end
end, opts)
end
return M
If it's desired I can clean this up and make a pull request? Otherwise hopefully this super simple example will help others.
Hi,
there’s a picker for
Telescope
but not forfzf-lua
yet :)LazyVim.org seems to lean into using the later as default picker (if telescope is not enabled, it auto enables
fzf-lua
)The text was updated successfully, but these errors were encountered: