I want to run a bash command on writing a .less file, saving it and generating the corresponding .css file with the same name and in the same directory. I do have the bash command which generates the .css file.
I'm not used to vimscript except for working with vim and changing some stuff in my .vimrc, so I'm not sure how to get this to work.
To sum it up:
- How do I run a bash command on
:w? - How do I get the current file directory (vimscript or bash)?
- How do I get the current file name (vimscript or bash)?