I have a website on my local computer running Mac OS X. I am wondering if there is any built-in command that I can run in the Terminal that will upload that website to my webserver through SFTP. Installing new commands through MacPorts is a possibility. A big bonus would be that it only uploaded the files that needs to be updated and not everything else.
It would also be nice if I can tell it to delete the files on the server that no longer exists locally once in a while.
Any good tips?
Update: This question asked about both SFTP and FTP, but I've only gotten an answer regarding SFTP.
rsync seems to do it very well when the server supports ssh, but if I have understood correctly,
rsync does not support FTP. I'm still looking for a good solution for FTP, so have opened a different question for it.