Jump to content

Command Crate ¿about?

Sync files with exclusions using over SSH (rsync)

rsync -avz --delete --prune-empty-dirs \
    --exclude='.ignore*' \
    --exclude='*.db-wal' \
    --exclude='*.db-shm' \
    -e "ssh -p $SSH_PORT -C" \
    "$LOCAL_FOLDER/" "$REMOTE_USER@$REMOTE_HOST:$REMOTE_FOLDER"

Syncs local files to a remote server via SSH, excluding specific files and deleting obsolete ones.

file management [kb:200]