atm3-deploy-http-push
Advanced tools
Comparing version 1.0.4 to 1.0.5
15
index.js
@@ -14,4 +14,4 @@ /** | ||
receiver, null, { | ||
to: to + release | ||
}, content, subpath, | ||
to: encodeURIComponent(to + release) | ||
}, content, encodeURIComponent(subpath), | ||
function(err, res) { | ||
@@ -61,2 +61,3 @@ if (err || res.trim() != '0') { | ||
reTryCount = options.retry, | ||
ignoreExt = options.ignoreExt, | ||
zipFile = options.file || "publish/publish.zip"; | ||
@@ -102,2 +103,5 @@ var receiver = options.receiver; | ||
modified.forEach(function(file) { | ||
if(ignoreExt.indexOf(file.ext) != -1){ | ||
return; | ||
} | ||
if (!file.release) { | ||
@@ -116,4 +120,6 @@ fis.log.error('unable to get release path of file[' + file.realpath + ']: Maybe this file is neither in current project or releasable'); | ||
steps.push(function(next) { | ||
if(ignoreExt.indexOf(file.ext) != -1){ | ||
return; | ||
} | ||
var _upload = arguments.callee; | ||
upload(receiver, to, file.getHashRelease(), file.getContent(), file, function(error) { | ||
@@ -143,3 +149,4 @@ if (error) { | ||
// 允许重试两次。 | ||
retry: 2 | ||
retry: 2, | ||
ignoreExt: [".zip"] | ||
}; |
{ | ||
"name": "atm3-deploy-http-push", | ||
"version": "1.0.4", | ||
"version": "1.0.5", | ||
"description": "atm3 deploy http-push plugin", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
9251
6
133