I have a local folder which I want to synchronize with a remote folder through SSH, and I'd like to do it through rsync. I would always call rsync with the same arguments, and same source and destination, when I want to sync this specific folder.Is there a way to create a folder-specific configuration file for rsync, placed in this local folder, so that when I simply run rsync in this folder, it will automatically take the defaults from the configuration file and start synching? Something like how you'd simply call git status in a folder, and it reads the repo from there - no further arguments about the path to the repo given.
Invoke rsync with specific defaults for current folder?
ssh;rsync
You should write your own little shell script for that. For example, myrsync in your PATH holding:#!/bin/bashok(){  if [ -t 0 ] &&     read -p ok? $* ?  reply &&      [ $reply = y -o $reply = ok ]   then $@  fi}if [ -f .myrsync ]then ok rsync $(<.myrsync)else echo no .myrsync here in $PWDfiThis has a function ok that tests that stdin is a terminal, then prompts you with the rsync command it has found and if you reply y it runs it.The rest of the script tests for a file .myrsync and if so runs the function on its contents.