如何在Windows上获取rsync命令?

问题描述:

我正在使用飞行计划来在生产环境中部署我的node.js应用程序。 这是我的flightplan.js文件。如何在Windows上获取rsync命令?

var plan = require('flightplan'); 

plan.target('default', { 
    host: {{host}}, 
    username: {{ username }}, 
    port: '2222', 
    agent: process.env.SSH_AUTH_SOCK 
}); 

plan.local(function(local) { 
    local.log('Copy files to remote hosts'); 
    var filesToCopy = local.exec('git ls-files', { silent: true }); 
    // rsync files to all the destination's hosts 
    local.transfer(filesToCopy, '~/www/'); 
}); 

当我跑飞默认情况下它停止并说

“rsync的”不被识别为一个内部或外部命令

我怎样才能得到rsync命令?我运行Windows 8

+1

Rsync是仅适用于基于Linux操作系统..有没有rsync命令在Windows – Billy

您可以安装cwRsync的免费版本:

https://www.itefix.net/content/cwrsync-free-edition

解压缩所有文件到c:\的rsync例如,再加入C:\ rsync将你的路径。

这里是在你的路径添加在Windows文件夹的教程:http://windowsitpro.com/systems-management/how-can-i-add-new-folder-my-system-path

+0

谢谢! Rsync是惊人的,真的想在我的桌面上。 – BRogers