I\'m looking for a way to map the :w command so that when I use it, it will rsync the current directory and save the file in question. Ideally, the response generated by the rsy
You can hook into BufWritePost. I don't remember the exact syntax, but ":he BufWritePost
" and ":he autocommand
" should help you.
You setup a basic hook like this (pattern matches on a file, so you can do *.your_extension):
:au BufWritePost * !rsync
Also, there should be some way to make it buffer-local.