Created
January 28, 2013 08:50
-
-
Save tiendq/4654000 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var cmd = "MSBuild"; | |
var sourcePath = "C:\\Store.Web\\"; | |
var profile = "Release"; | |
var buildPath = "C:\\Build"; | |
// Temporary folder must ends with slash. | |
var tempPath = buildPath + "\\Temp\\"; | |
var outputPath = buildPath + "\\Output\\Store.zip"; | |
// Log folder must exist. | |
var logPath = buildPath + "\\Logs\\MSBuild-Store.log"; | |
var params = [ | |
sourcePath + "Store.Web.csproj", | |
"/t:Rebuild", | |
"/p:Configuration=" + profile, | |
"/p:DeployOnBuild=true", | |
"/p:DeployTarget=Package", | |
"/p:PublishProfile=" + profile, | |
"/p:VisualStudioVersion=11.0", | |
"/p:PackageLocation=" + outputPath, | |
"/p:BaseIntermediateOutputPath=" + tempPath, | |
"/fl", | |
"/flp:Verbosity=normal;LogFile=" + logPath]; | |
var spawn = require("child_process").spawn; | |
var app = spawn(cmd, params); | |
app.stdout.on("data", function (data) | |
{ | |
console.log("" + data); | |
}); | |
app.stderr.on("data", function (data) | |
{ | |
console.log("" + data); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment