Skip to content

Commit

Permalink
Fix jsonnetfmt passing junk "-path" argument
Browse files Browse the repository at this point in the history
  • Loading branch information
dbarnett committed Nov 24, 2023
1 parent 03b8f30 commit 1339fa5
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions autoload/codefmt/jsonnetfmt.vim
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,7 @@ function! codefmt#jsonnetfmt#GetFormatter() abort
" Reformat the current buffer with jsonnetfmt or the binary named in
" @flag(jsonnetfmt_executable)
function l:formatter.Format() abort
let l:cmd = [ s:plugin.Flag('jsonnetfmt_executable') ]
let l:fname = expand('%:p')
if !empty(l:fname)
let l:cmd += ['-path', l:fname]
endif
let l:cmd = [ s:plugin.Flag('jsonnetfmt_executable'), '-' ]

try
" NOTE: Ignores any line ranges given and formats entire buffer.
Expand Down

0 comments on commit 1339fa5

Please sign in to comment.