#####Nobone-sync
nobone-sync 是一个远程文件同步开发工具,可以在本地开发远程同步到服务器。
npm install -g nobone-sync
npm install nobone-sync
nobone-sync -s
nobone-sync config.js
//config.js是本地配置nobone-sync的js文件路径
module.exports = {
localDir: 'localDir',
remoteDir: 'remoteDir', //远程服务器上改项目文件路径地址
rootAllowed: '/',
host: 'hostip',服务器地址
port: 8345,
pattern: '**',
pollingInterval: 500,
password: null,
algorithm: 'aes128',
onChange: function (type, path, oldPath) {
// It can also return a promise.
console.log('Write your custom code here')
}
}
//注解:The pattern can be a string or an array, it takes advantage of minimatch.
github地址