Skip to content
This repository has been archived by the owner on Aug 16, 2021. It is now read-only.

Commit

Permalink
--window option was not being added to the arry correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
chris-sanders committed Aug 5, 2021
1 parent 321d556 commit d4820c2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lua/zk/adapter.lua
Original file line number Diff line number Diff line change
Expand Up @@ -129,9 +129,10 @@ local function handle_fzf(opts)
if vim.fn.executable("bat") == 1 then
-- NOTE: 5 is the number that prevents overflow of the preview window when using bat
preview = "bat -p --line-range=:$(($FZF_PREVIEW_LINES - 5)) --color always {}"
table.insert(opts.fzf_opts, string.format("--preview=%s", vim.fn.shellescape(preview)))
end

opts.fzf_opts["--preview"] = ("--preview=%s"):format(vim.fn.shellescape(preview))
-- opts.fzf_opts["--preview"] = ("--preview=%s"):format(vim.fn.shellescape(preview))

local fzf_opts = table.concat(opts.fzf_opts, " ")

Expand Down

0 comments on commit d4820c2

Please sign in to comment.