Retab some files
This commit is contained in:
parent
50cc8ca0be
commit
01624e0c71
3 changed files with 15 additions and 15 deletions
|
@ -4,7 +4,7 @@ function! TryAutosave()
|
|||
if &autowriteall
|
||||
if &mod
|
||||
silent write
|
||||
redraw
|
||||
redraw
|
||||
end
|
||||
end
|
||||
endfunction
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
function Defer(command, callback)
|
||||
let l:buffer = []
|
||||
call job_start(a:command, {
|
||||
\ "out_io": "pipe",
|
||||
\ "out_cb": { pipe, text -> add(l:buffer, text) },
|
||||
\ "close_cb": { pipe -> a:callback(l:buffer) }
|
||||
\ })
|
||||
let l:buffer = []
|
||||
call job_start(a:command, {
|
||||
\ "out_io": "pipe",
|
||||
\ "out_cb": { pipe, text -> add(l:buffer, text) },
|
||||
\ "close_cb": { pipe -> a:callback(l:buffer) }
|
||||
\ })
|
||||
endfun
|
||||
|
||||
comm -complete=shellcmd -nargs=* Defer call Defer(<q-args>, { buffer -> 0 })
|
||||
|
|
|
@ -24,14 +24,14 @@ augroup NETRW
|
|||
augroup END
|
||||
|
||||
function s:vex()
|
||||
let netrw_windows = getwininfo()
|
||||
\->filter({ k,v -> v["variables"]->has_key("netrw_treedict") })
|
||||
\->filter({ k,v -> v["tabnr"]==tabpagenr() })
|
||||
if netrw_windows->len() > 0
|
||||
call win_gotoid(netrw_windows[0]["winid"])
|
||||
else
|
||||
Vex .
|
||||
end
|
||||
let netrw_windows = getwininfo()
|
||||
\->filter({ k,v -> v["variables"]->has_key("netrw_treedict") })
|
||||
\->filter({ k,v -> v["tabnr"]==tabpagenr() })
|
||||
if netrw_windows->len() > 0
|
||||
call win_gotoid(netrw_windows[0]["winid"])
|
||||
else
|
||||
Vex .
|
||||
end
|
||||
endfun
|
||||
|
||||
nnoremap <leader><space> :call <SID>vex()<CR>
|
||||
|
|
Loading…
Reference in a new issue