Skip to content

Commit

Permalink
Merge pull request #287 from ibilon/devDepNoInstall
Browse files Browse the repository at this point in the history
Don't install version-less dependencies that have a dev set
  • Loading branch information
nadako committed Mar 10, 2016
2 parents 2b0cd09 + c08fbcb commit fa6c4e9
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/haxelib/client/Main.hx
Original file line number Diff line number Diff line change
Expand Up @@ -808,7 +808,18 @@ class Main {

function doInstallDependencies( dependencies:Array<Dependency> )
{
var rep = getRepository();

for( d in dependencies ) {
if( d.version == "" ) {
var pdir = rep + Data.safe(d.name);
var dev = try getDev(pdir) catch (_:Dynamic) null;

if (dev != null) { // no version specified and dev set, no need to install dependency
continue;
}
}

print("Installing dependency "+d.name+" "+d.version);
if( d.version == "" )
d.version = site.infos(d.name).getLatest();
Expand Down

0 comments on commit fa6c4e9

Please sign in to comment.