rsync a single file

I have been using rsync scripts for a while and use them to sync directories across my servers. However i need to set up an rsync script to copy only one file from a server. Is this possible with rsync? If so how would i do this? I have looked on examples on the internet and only see examples for whole directories.

Well, the man says path is a dir. You could rsync the parent dir and set the filter to exclude all others or include only this file.

rsyncd.conf(5) - Linux man page

Another possibility is to work around it by putting the flat file alone in a new dir, and sym-link or link it to be acessible from the original path. Just note that a sym-link imposes a slight cost at open. While rsync of any kind of link may have various problems and restrictions, it will certainly work if both ends are single linked flat files in the new dir, and the original path has a sym-link to it. Whether the apps on both ends are happy opening the sym-links in orignal paths is an additional question.

Hi thanks,

Been playing around trial and error style and tried some things.

I tried:

rsync -avz host:/path/to/file/file.csv /path/to/file/file.csv

That seemed to only do the one file and the file looks like it updated. Thanks