in .vimrc:
au BufWritePost *.less silent !lessc <afile> --source-map <afile>:r.css au BufWritePost *.coffee silent make -m
Additional, run ruby:
map <leader>r :!ruby %<cr>
Note:
<afile>
is thepath/file.extension
of current file<afile>:r
is thepath/file
of current file- substitute
lessc
for/usr/local/bin/lessc
or others if you want to specify another lessc to use - the
--source-map
and-m
options specify sourcemap