mirror of
https://github.com/keanuplayz/dotfiles.git
synced 2024-08-15 02:33:12 +00:00
[nvim] use the built-in expansion mechanism in makeprg
This commit is contained in:
parent
eea04f738e
commit
432cb47135
3 changed files with 3 additions and 15 deletions
|
@ -1,11 +1,5 @@
|
||||||
source <sfile>:h/text.vim
|
source <sfile>:h/text.vim
|
||||||
|
|
||||||
let s:src_file = expand('%')
|
let &l:makeprg = 'markdown2htmldoc -- %:S %:S.html'
|
||||||
let s:out_file = s:src_file.'.html'
|
|
||||||
let &l:makeprg = 'markdown2htmldoc'
|
|
||||||
for s:arg in get(g:, 'dotfiles_markdown2htmldoc_options', [])
|
|
||||||
let &l:makeprg .= ' '.shellescape(s:arg)
|
|
||||||
endfor
|
|
||||||
let &l:makeprg .= ' -- '.shellescape(s:src_file).' '.shellescape(s:out_file)
|
|
||||||
|
|
||||||
nnoremap <buffer> <F5> <Cmd>Open %.html<CR>
|
nnoremap <buffer> <F5> <Cmd>Open %.html<CR>
|
||||||
|
|
|
@ -1,9 +1,3 @@
|
||||||
source <sfile>:h/css.vim
|
source <sfile>:h/css.vim
|
||||||
|
|
||||||
let s:src_file = expand('%')
|
let &l:makeprg = 'sass -- %:S:%:S.css'
|
||||||
let s:out_file = s:src_file.'.css'
|
|
||||||
let &l:makeprg = 'sass'
|
|
||||||
for s:arg in get(g:, 'dotfiles_dart_sass_options', [])
|
|
||||||
let &l:makeprg .= ' '.shellescape(s:arg)
|
|
||||||
endfor
|
|
||||||
let &l:makeprg .= ' -- '.shellescape(s:src_file).':'.shellescape(s:out_file)
|
|
||||||
|
|
|
@ -139,4 +139,4 @@ endif
|
||||||
" }}}
|
" }}}
|
||||||
|
|
||||||
|
|
||||||
nnoremap <silent> <F9> <Cmd>make<CR>
|
nnoremap <silent> <F9> <Cmd>make!<CR>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue