Rsync two folders

If you want to rsync two folders, do rsync -avu --delete "hugo/public/" "/blog/content"
. I kept a /
at the end of hugo/public
, this means that it will only copy the content of the public
folder. If you remove this, it will take the folder. The parameters mean:
-a
Do the sync preserving all filesystem attributes-v
run verbosely-u
only copy files with a newer modification time (or size difference if the times are equal)--delete
delete the files in target folder that do not exist in the source
Hope you can use it to something.
Read other posts