Gitbash中的rsync(cwrsync) - 源和目标不能都是远程的.[Windows 7的]

Rep*_*ile 9 windows rsync cwrsync git-bash

我试图在Windows 7中使用Git Bash将本地路径同步到另一个驱动器.我下载了cwRsync并将文件复制到我的Git bash bin目录.我可以运行rsync但是以下命令给我带来了问题

rsync -av/c/00-dev/05-batch/f/RSYNC /源和目标不能都是远程的.rsync错误:main.c上的语法或用法错误(代码1)(1135)[receiver = 3.0.6]

两条路径都是正确的,但不会同步.

小智 10

解决方法:cd/crsync使用相对路径.

这样可行:

cd /c
touch temp/test.txt
rsync temp/test.txt temp/test2.txt
Run Code Online (Sandbox Code Playgroud)

虽然这不,即使你cd/c:

$ rsync /c/temp/test.txt /c/temp/test2.txt
The source and destination cannot both be remote.
Run Code Online (Sandbox Code Playgroud)

使用随附的Git Bash进行测试git 2.9.0.windows.1.