Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files
rejiggered to avoid extra bat files. RegReading is done in jscript
  • Loading branch information
purplecabbage committed Jan 10, 2014
1 parent 64afa53 commit 6e9b38f24ee8bfd9aad61d7bd3b6e70de17c2fc7
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 42 deletions.

This file was deleted.

@@ -87,13 +87,20 @@ else {
* in the environment PATH variable.
* - msbuild (ex. C:\\Windows\\Microsoft.NET\\Framework\\v4.0.30319)
*/
var cmd = 'GetMSBuildToolsVersion.bat';
var fail_msg = 'The command `msbuild` failed. Make sure you have the latest Windows Phone SDKs installed, AND have the latest .NET framework added to your path (i.e C:\\Windows\\Microsoft.NET\\Framework\\v4.0.30319).'
var output = check_command(cmd, fail_msg);
var version;

if(output.indexOf("4.0") != 0) {
try {
version = wscript_shell.RegRead("HKLM\\SOFTWARE\\Microsoft\\MSBuild\\ToolsVersions\\4.0\\MSBuildRuntimeVersion");
if(version != null && version.indexOf("4.0") == 0) {
// All good!
Log(version);
}
else {
throw(new Error("version not 4.0"));
}
}
catch(err) {
Log('Please install the .NET Framework v4.0 (part of the latest windows phone SDK\'s).', true);
Log("Reported version is : " + output);
WScript.Quit(1);
}
}

This file was deleted.

@@ -87,13 +87,20 @@ else {
* in the environment PATH variable.
* - msbuild (ex. C:\\Windows\\Microsoft.NET\\Framework\\v4.0.30319)
*/
var cmd = 'GetMSBuildToolsVersion.bat';
var fail_msg = 'The command `msbuild` failed. Make sure you have the latest Windows Phone SDKs installed, AND have the latest .NET framework added to your path (i.e C:\\Windows\\Microsoft.NET\\Framework\\v4.0.30319).'
var output = check_command(cmd, fail_msg);
var version;

if(output.indexOf("4.0") != 0) {
try {
version = wscript_shell.RegRead("HKLM\\SOFTWARE\\Microsoft\\MSBuild\\ToolsVersions\\4.0\\MSBuildRuntimeVersion");
if(version != null && version.indexOf("4.0") == 0) {
// All good!
Log(version);
}
else {
throw(new Error("version not 4.0"));
}
}
catch(err) {
Log('Please install the .NET Framework v4.0 (part of the latest windows phone SDK\'s).', true);
Log("Reported version is : " + output);
WScript.Quit(1);
}
}

0 comments on commit 6e9b38f

Please sign in to comment.