Fix version mismatch, fix null check
This commit is contained in:
@@ -1116,7 +1116,7 @@ class HXProject {
|
||||
var name = haxelib.name;
|
||||
var version = HaxelibHelper.getVersion (haxelib);
|
||||
|
||||
if (haxelib.version != null) {
|
||||
if (version != null) {
|
||||
|
||||
name += ":" + version;
|
||||
|
||||
|
||||
@@ -242,6 +242,18 @@ class HaxelibHelper {
|
||||
|
||||
LogHelper.error ("Could not find haxelib \"" + dependencyName + "\" (dependency of \"" + haxelib.name + "\"), does it need to be installed?");
|
||||
|
||||
} else if (output.indexOf ("is not installed") > -1) {
|
||||
|
||||
var start = output.indexOf ("Library " + 8);
|
||||
var end = output.indexOf (" ", start);
|
||||
var dependencyName = output.substring (start, end);
|
||||
|
||||
start = output.indexOf ("version ") + 8;
|
||||
end = output.indexOf (" ", start);
|
||||
var version = output.substring (start, end);
|
||||
|
||||
LogHelper.error ("Could not find haxelib \"" + dependencyName + "\" version \"" + version + "\", does it need to be installed?");
|
||||
|
||||
} else {
|
||||
|
||||
if (haxelib.version != "") {
|
||||
|
||||
@@ -1290,7 +1290,7 @@ class Main {
|
||||
var dev = try getDev(pdir) catch (_:Dynamic) null;
|
||||
var vdir = try getVersionDir(version,dev,pdir) catch (_:Dynamic) null;
|
||||
|
||||
if( vdir != null && !FileSystem.exists(vdir) )
|
||||
if( vdir == null || !FileSystem.exists(vdir) )
|
||||
throw "Library "+prj+" version "+version+" is not installed";
|
||||
|
||||
for( p in l )
|
||||
|
||||
Reference in New Issue
Block a user