diff --git a/Session.vim b/Session.vim index 2dce5b2..c5911bd 100644 --- a/Session.vim +++ b/Session.vim @@ -13,10 +13,11 @@ if &shortmess =~ 'A' else set shortmess=aoO endif -badd +57 templates/nushell.txt +badd +47 templates/nushell.txt +badd +0 oil:///home/felix/coding/OpenSource/zoxide/ argglobal %argdel -$argadd . +$argadd oil:///home/felix/coding/OpenSource/zoxide/ edit templates/nushell.txt wincmd t let s:save_winminheight = &winminheight @@ -34,12 +35,12 @@ setlocal fdl=99 setlocal fml=1 setlocal fdn=99 setlocal fen -let s:l = 57 - ((19 * winheight(0) + 11) / 23) +let s:l = 47 - ((36 * winheight(0) + 27) / 55) if s:l < 1 | let s:l = 1 | endif keepjumps exe s:l normal! zt -keepjumps 57 -normal! 041| +keepjumps 47 +normal! 043| tabnext 1 if exists('s:wipebuf') && len(win_findbuf(s:wipebuf)) == 0 && getbufvar(s:wipebuf, '&buftype') isnot# 'terminal' silent exe 'bwipe ' . s:wipebuf diff --git a/templates/nushell.txt b/templates/nushell.txt index e3381af..887fe36 100644 --- a/templates/nushell.txt +++ b/templates/nushell.txt @@ -44,7 +44,7 @@ def --env __zoxide_z [...rest:string] { let path = if (($rest | length) <= 1) and ($arg0 == '-' or ($arg0 | path expand | path type) == dir) { $arg0 } else { - (zoxide query --exclude $env.PWD -- $rest | str trim -r -c "\n") + (zoxide query --exclude $env.PWD -- ...$rest | str trim -r -c "\n") } cd $path {%- if echo %}