fis-command-release
Advanced tools
Comparing version 0.3.7 to 0.3.8
@@ -8,3 +8,3 @@ /* | ||
function upload(receiver, to, release, file, fis){ | ||
function upload(receiver, to, release, file){ | ||
fis.util.upload( | ||
@@ -24,9 +24,9 @@ //url, request options, post data, file | ||
function deploy(dest, file, fis){ | ||
function deploy(dest, file){ | ||
if(dest.receiver){ | ||
if(!file.useHash || dest.md5 != 1){ | ||
upload(dest.receiver, dest.to, file.release, file, fis); | ||
upload(dest.receiver, dest.to, file.release, file); | ||
} | ||
if(file.useHash && dest.md5 > 0){ | ||
upload(dest.receiver, dest.to, file.getHashRelease(), file, fis); | ||
upload(dest.receiver, dest.to, file.getHashRelease(), file); | ||
} | ||
@@ -42,3 +42,3 @@ } else { | ||
module.exports = function(dest, md5, collection, fis){ | ||
module.exports = function(dest, md5, collection){ | ||
var settings = fis.config.get('deploy', {}); | ||
@@ -66,3 +66,3 @@ var root = fis.project.getProjectPath(); | ||
if(file.release.indexOf(d.from) === 0 && fis.util.filter(file.subpath, d.include, d.exclude)){ | ||
deploy(d, file, fis); | ||
deploy(d, file); | ||
} | ||
@@ -69,0 +69,0 @@ }); |
{ | ||
"name" : "fis-command-release", | ||
"description" : "fis release command.", | ||
"version" : "0.3.7", | ||
"version" : "0.3.8", | ||
"author" : "FIS Team <fis@baidu.com>", | ||
@@ -6,0 +6,0 @@ "homepage" : "http://fis.baidu.com/", |
@@ -10,3 +10,3 @@ /* | ||
exports.desc = 'build and deploy your project'; | ||
exports.register = function(commander, fis){ | ||
exports.register = function(commander){ | ||
@@ -78,3 +78,3 @@ function watch(opt){ | ||
fis.util.map(ret.pkg, collection, true); | ||
deploy(opt.dest, opt.md5, collection, fis); | ||
deploy(opt.dest, opt.md5, collection); | ||
collection = {}; | ||
@@ -81,0 +81,0 @@ return; |
10891