fix(sioyek): pass abspath in synctex script
This commit is contained in:
parent
f1cc5ca1ba
commit
66c1be4b45
3 changed files with 10 additions and 3 deletions
|
|
@ -4,6 +4,7 @@ local Methods = vim.lsp.protocol.Methods
|
||||||
|
|
||||||
local function fzf_or(fzf_cmd, fallback)
|
local function fzf_or(fzf_cmd, fallback)
|
||||||
return function()
|
return function()
|
||||||
|
pcall(require('lz.n').trigger_load, 'ibhagwan/fzf-lua')
|
||||||
if pcall(require, 'fzf-lua') then
|
if pcall(require, 'fzf-lua') then
|
||||||
vim.cmd('FzfLua ' .. fzf_cmd)
|
vim.cmd('FzfLua ' .. fzf_cmd)
|
||||||
else
|
else
|
||||||
|
|
|
||||||
|
|
@ -161,7 +161,7 @@ in
|
||||||
font_size 18
|
font_size 18
|
||||||
status_bar_font_size 18
|
status_bar_font_size 18
|
||||||
|
|
||||||
inverse_search_command nvim-inverse-search %1 %2
|
inverse_search_command ${repoDir}/scripts/nvim-inverse-search %1 %2
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -2,11 +2,17 @@
|
||||||
file="$1"
|
file="$1"
|
||||||
line="$2"
|
line="$2"
|
||||||
|
|
||||||
|
echo "$(date) file='$file' line='$line'" >> ~/.debug
|
||||||
|
|
||||||
for sock in /run/user/$(id -u)/nvim.*.0; do
|
for sock in /run/user/$(id -u)/nvim.*.0; do
|
||||||
[ -S "$sock" ] || continue
|
[ -S "$sock" ] || continue
|
||||||
result=$(nvim --server "$sock" --remote-expr "bufnr('$file')" 2>/dev/null)
|
result=$(nvim --server "$sock" --remote-expr "bufnr('$file')" 2>&1)
|
||||||
|
echo " sock='$sock' bufnr='$result'" >> ~/.debug
|
||||||
if [ "$result" != "-1" ] && [ -n "$result" ]; then
|
if [ "$result" != "-1" ] && [ -n "$result" ]; then
|
||||||
nvim --server "$sock" --remote-expr "execute('b +$line $file | normal! zz')"
|
out=$(nvim --server "$sock" --remote-expr "execute('b +$line $file | normal! zz')" 2>&1)
|
||||||
|
echo " -> sent, result='$out'" >> ~/.debug
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
|
echo " -> no match found" >> ~/.debug
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue