diff --git a/BuildServer/lib/tasks/dotnetnugetpack.js b/BuildServer/lib/tasks/dotnetnugetpack.js index 55327dc..a22614d 100644 --- a/BuildServer/lib/tasks/dotnetnugetpack.js +++ b/BuildServer/lib/tasks/dotnetnugetpack.js @@ -4,7 +4,7 @@ var sequential = require('./sequential'); module.exports = function (params, processor) { var date = new Date(), - version = (params.version || ((params.major || "0") + "." + (date.getFullYear() * 10000 + (date.getMonth() + 1) * 100 + date.getDate()) + "." + ((date.getHours() * 100 + date.getMinutes()) * 100 + date.getSeconds()))) + "-r" + processor.context.rev.substr(0, 16), + version = (params.version || ((params.major || "0") + "." + (date.getFullYear() * 10000 + (date.getMonth() + 1) * 100 + date.getDate()) + "." + ((date.getHours() * 100 + date.getMinutes()) * 100 + date.getSeconds()))) + (params.withoutCommitSha ? "" : ("-r" + processor.context.rev.substr(0, 16))), nupkg = processor.context.exported + "/" + params.name + "." + version + ".nupkg"; return sequential({ diff --git a/BuildServer/lib/tasks/dotnetnugetprocess.js b/BuildServer/lib/tasks/dotnetnugetprocess.js index 2e7a722..ad09d88 100644 --- a/BuildServer/lib/tasks/dotnetnugetprocess.js +++ b/BuildServer/lib/tasks/dotnetnugetprocess.js @@ -12,6 +12,7 @@ module.exports = function (params, processor) { "params": { "nuspec": params.nuspecName + ".nuspec", "name": params.nuspecName, + "withoutCommitSha": params.withoutCommitSha, "version": params.version, "major": params.major } @@ -21,6 +22,7 @@ module.exports = function (params, processor) { "type": "dotnetnugetpack", "params": { "nuspec": params.nuspecName + ".nuspec", + "withoutCommitSha": params.withoutCommitSha, "version": params.version, "major": params.major } diff --git a/BuildServer/lib/tasks/dotnetnugetpush.js b/BuildServer/lib/tasks/dotnetnugetpush.js index 2ac89f9..dadf447 100644 --- a/BuildServer/lib/tasks/dotnetnugetpush.js +++ b/BuildServer/lib/tasks/dotnetnugetpush.js @@ -5,7 +5,7 @@ var settings = require("../../settings"); module.exports = function (params, processor) { var date = new Date(), - version = (params.version || ((params.major || "0") + "." + (date.getFullYear() * 10000 + (date.getMonth() + 1) * 100 + date.getDate()) + "." + ((date.getHours() * 100 + date.getMinutes()) * 100 + date.getSeconds()))) + "-r" + processor.context.rev.substr(0, 16), + version = (params.version || ((params.major || "0") + "." + (date.getFullYear() * 10000 + (date.getMonth() + 1) * 100 + date.getDate()) + "." + ((date.getHours() * 100 + date.getMinutes()) * 100 + date.getSeconds()))) + (params.withoutCommitSha ? "" : ("-r" + processor.context.rev.substr(0, 16))), nupkg = params.name + "." + version + ".nupkg"; return sequential({