mirror of
https://github.com/keanuplayz/dotfiles.git
synced 2024-08-15 02:33:12 +00:00
[nvim] allow compiling S[AC]SS stylesheets with F9
This commit is contained in:
parent
630d6885a1
commit
796a8a9c4d
3 changed files with 11 additions and 1 deletions
|
@ -2,9 +2,10 @@ source <sfile>:h/text.vim
|
|||
|
||||
let s:src_file = expand('%')
|
||||
let s:out_file = s:src_file.'.html'
|
||||
let &l:makeprg = 'markdown2htmldoc '.shellescape(s:src_file).' '.shellescape(s:out_file)
|
||||
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>
|
||||
|
|
1
nvim/after/ftplugin/sass.vim
Normal file
1
nvim/after/ftplugin/sass.vim
Normal file
|
@ -0,0 +1 @@
|
|||
source <sfile>:h/scss.vim
|
|
@ -1 +1,9 @@
|
|||
source <sfile>:h/css.vim
|
||||
|
||||
let s:src_file = expand('%')
|
||||
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)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue