// Compiled by ClojureScript 1.9.293 {:target :nodejs}
goog.provide('eginez.huckleberry.core');
goog.require('cljs.core');
goog.require('eginez.huckleberry.os');
goog.require('clojure.set');
goog.require('cljs.core.async');
goog.require('cljs.nodejs');
goog.require('clojure.string');
eginez.huckleberry.core.default_repos = new cljs.core.PersistentArrayMap(null, 3, [new cljs.core.Keyword(null,"clojars","clojars",1050810118),"https://clojars.org/repo",new cljs.core.Keyword(null,"local","local",-1497766724),clojure.string.join.call(null,eginez.huckleberry.os.SEPARATOR,new cljs.core.PersistentVector(null, 3, 5, cljs.core.PersistentVector.EMPTY_NODE, [eginez.huckleberry.os.HOME_DIR,".m2","repository"], null)),new cljs.core.Keyword(null,"maven-central","maven-central",-580926359),"https://repo1.maven.org/maven2"], null);
eginez.huckleberry.core.is_url_local_QMARK_ = (function eginez$huckleberry$core$is_url_local_QMARK_(url){
return !(clojure.string.starts_with_QMARK_.call(null,url,"http"));
});
eginez.huckleberry.core.create_remote_url_for_depedency = (function eginez$huckleberry$core$create_remote_url_for_depedency(repo,p__19214){
var map__19217 = p__19214;
var map__19217__$1 = ((((!((map__19217 == null)))?((((map__19217.cljs$lang$protocol_mask$partition0$ & (64))) || ((cljs.core.PROTOCOL_SENTINEL === map__19217.cljs$core$ISeq$)))?true:false):false))?cljs.core.apply.call(null,cljs.core.hash_map,map__19217):map__19217);
var group = cljs.core.get.call(null,map__19217__$1,new cljs.core.Keyword(null,"group","group",582596132));
var artifact = cljs.core.get.call(null,map__19217__$1,new cljs.core.Keyword(null,"artifact","artifact",610074681));
var version = cljs.core.get.call(null,map__19217__$1,new cljs.core.Keyword(null,"version","version",425292698));
var sep = (cljs.core.truth_(eginez.huckleberry.core.is_url_local_QMARK_.call(null,repo))?"/":eginez.huckleberry.os.SEPARATOR);
var g = clojure.string.replace.call(null,group,/\./,sep);
var art = clojure.string.join.call(null,"-",new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [artifact,version], null));
var art_url = clojure.string.join.call(null,sep,new cljs.core.PersistentVector(null, 5, 5, cljs.core.PersistentVector.EMPTY_NODE, [repo,g,artifact,version,art], null));
var ext = new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, ["pom","jar"], null);
return new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [repo,cljs.core.map.call(null,((function (sep,g,art,art_url,ext,map__19217,map__19217__$1,group,artifact,version){
return (function (p1__19213_SHARP_){
return clojure.string.join.call(null,".",new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [art_url,p1__19213_SHARP_], null));
});})(sep,g,art,art_url,ext,map__19217,map__19217__$1,group,artifact,version))
,ext)], null);
});
eginez.huckleberry.core.create_urls_for_dependency = (function eginez$huckleberry$core$create_urls_for_dependency(repos,d){
if(cljs.core.coll_QMARK_.call(null,repos)){
return cljs.core.map.call(null,(function (p1__19219_SHARP_){
return eginez.huckleberry.core.create_remote_url_for_depedency.call(null,p1__19219_SHARP_,d);
}),repos);
} else {
return eginez.huckleberry.core.create_remote_url_for_depedency.call(null,repos,d);
}
});
eginez.huckleberry.core.read_url_chan = (function eginez$huckleberry$core$read_url_chan(cout,url){
if(cljs.core.truth_(eginez.huckleberry.core.is_url_local_QMARK_.call(null,url))){
return eginez.huckleberry.os.read_file.call(null,cout,url);
} else {
return eginez.huckleberry.os.make_http_request.call(null,cout,url);
}
});
eginez.huckleberry.core.mvndep__GT_dep = (function eginez$huckleberry$core$mvndep__GT_dep(x){
var g = cljs.core.first.call(null,new cljs.core.Keyword(null,"groupId","groupId",-921143743).cljs$core$IFn$_invoke$arity$1(x));
var a = cljs.core.first.call(null,new cljs.core.Keyword(null,"artifactId","artifactId",1019340147).cljs$core$IFn$_invoke$arity$1(x));
var v = cljs.core.first.call(null,new cljs.core.Keyword(null,"version","version",425292698).cljs$core$IFn$_invoke$arity$1(x));
var m = new cljs.core.PersistentArrayMap(null, 3, [new cljs.core.Keyword(null,"group","group",582596132),g,new cljs.core.Keyword(null,"artifact","artifact",610074681),a,new cljs.core.Keyword(null,"version","version",425292698),v], null);
return m;
});
eginez.huckleberry.core.dep__GT_path = (function eginez$huckleberry$core$dep__GT_path(x){
var vec__19226 = eginez.huckleberry.core.create_remote_url_for_depedency.call(null,new cljs.core.Keyword(null,"url","url",276297046).cljs$core$IFn$_invoke$arity$1(x),x);
var r = cljs.core.nth.call(null,vec__19226,(0),null);
var vec__19229 = cljs.core.nth.call(null,vec__19226,(1),null);
var pom = cljs.core.nth.call(null,vec__19229,(0),null);
var jar = cljs.core.nth.call(null,vec__19229,(1),null);
return jar;
});
eginez.huckleberry.core.dep__GT_coordinate = (function eginez$huckleberry$core$dep__GT_coordinate(dep){
return [cljs.core.str(new cljs.core.Keyword(null,"group","group",582596132).cljs$core$IFn$_invoke$arity$1(dep)),cljs.core.str("/"),cljs.core.str(new cljs.core.Keyword(null,"artifact","artifact",610074681).cljs$core$IFn$_invoke$arity$1(dep)),cljs.core.str(" "),cljs.core.str(new cljs.core.Keyword(null,"version","version",425292698).cljs$core$IFn$_invoke$arity$1(dep))].join('');
});
eginez.huckleberry.core.clean_deps = (function eginez$huckleberry$core$clean_deps(x){
var y = cljs.core.remove.call(null,(function (p1__19238_SHARP_){
return (cljs.core._EQ_.call(null,"test",cljs.core.first.call(null,new cljs.core.Keyword(null,"scope","scope",-439358418).cljs$core$IFn$_invoke$arity$1(p1__19238_SHARP_)))) || (cljs.core._EQ_.call(null,"true",cljs.core.first.call(null,new cljs.core.Keyword(null,"optional","optional",2053951509).cljs$core$IFn$_invoke$arity$1(p1__19238_SHARP_))));
}),x);
return y;
});
eginez.huckleberry.core.read_dependency_pipeline = (function eginez$huckleberry$core$read_dependency_pipeline(url_set){

var repo_url = cljs.core.first.call(null,url_set);
var pom_url = cljs.core.first.call(null,cljs.core.second.call(null,url_set));
var c = cljs.core.async.chan.call(null,(1),cljs.core.comp.call(null,cljs.core.map.call(null,eginez.huckleberry.os.parse_xml),cljs.core.map.call(null,((function (repo_url,pom_url){
return (function (p1__19239_SHARP_){
return cljs.core.js__GT_clj.call(null,p1__19239_SHARP_,new cljs.core.Keyword(null,"keywordize-keys","keywordize-keys",1310784252),true);
});})(repo_url,pom_url))
),cljs.core.map.call(null,((function (repo_url,pom_url){
return (function (p1__19240_SHARP_){
return cljs.core.get_in.call(null,p1__19240_SHARP_,new cljs.core.PersistentVector(null, 4, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"project","project",1124394579),new cljs.core.Keyword(null,"dependencies","dependencies",1108064605),(0),new cljs.core.Keyword(null,"dependency","dependency",1300131203)], null));
});})(repo_url,pom_url))
),cljs.core.map.call(null,eginez.huckleberry.core.clean_deps),cljs.core.map.call(null,((function (repo_url,pom_url){
return (function (p1__19241_SHARP_){
return cljs.core.map.call(null,eginez.huckleberry.core.mvndep__GT_dep,p1__19241_SHARP_);
});})(repo_url,pom_url))
),cljs.core.map.call(null,((function (repo_url,pom_url){
return (function (p1__19242_SHARP_){
return cljs.core.into.call(null,cljs.core.PersistentHashSet.EMPTY,p1__19242_SHARP_);
});})(repo_url,pom_url))
),cljs.core.map.call(null,((function (repo_url,pom_url){
return (function (p1__19243_SHARP_){
return cljs.core.conj.call(null,cljs.core.PersistentVector.EMPTY,repo_url,p1__19243_SHARP_);
});})(repo_url,pom_url))
)));
return eginez.huckleberry.core.read_url_chan.call(null,c,pom_url);
});
eginez.huckleberry.core.extract_dependencies = (function eginez$huckleberry$core$extract_dependencies(url_set){
return cljs.core.map.call(null,eginez.huckleberry.core.read_dependency_pipeline,url_set);
});
eginez.huckleberry.core.resolve = (function eginez$huckleberry$core$resolve(var_args){
var args__7658__auto__ = [];
var len__7651__auto___19366 = arguments.length;
var i__7652__auto___19367 = (0);
while(true){
if((i__7652__auto___19367 < len__7651__auto___19366)){
args__7658__auto__.push((arguments[i__7652__auto___19367]));

var G__19368 = (i__7652__auto___19367 + (1));
i__7652__auto___19367 = G__19368;
continue;
} else {
}
break;
}

var argseq__7659__auto__ = ((((1) < args__7658__auto__.length))?(new cljs.core.IndexedSeq(args__7658__auto__.slice((1)),(0),null)):null);
return eginez.huckleberry.core.resolve.cljs$core$IFn$_invoke$arity$variadic((arguments[(0)]),argseq__7659__auto__);
});

eginez.huckleberry.core.resolve.cljs$core$IFn$_invoke$arity$variadic = (function (dep,p__19261){
var map__19262 = p__19261;
var map__19262__$1 = ((((!((map__19262 == null)))?((((map__19262.cljs$lang$protocol_mask$partition0$ & (64))) || ((cljs.core.PROTOCOL_SENTINEL === map__19262.cljs$core$ISeq$)))?true:false):false))?cljs.core.apply.call(null,cljs.core.hash_map,map__19262):map__19262);
var repositories = cljs.core.get.call(null,map__19262__$1,new cljs.core.Keyword(null,"repositories","repositories",1367837581));
var local_repo = cljs.core.get.call(null,map__19262__$1,new cljs.core.Keyword(null,"local-repo","local-repo",764410280));
var c__13855__auto__ = cljs.core.async.chan.call(null,(1));
cljs.core.async.impl.dispatch.run.call(null,((function (c__13855__auto__,map__19262,map__19262__$1,repositories,local_repo){
return (function (){
var f__13856__auto__ = (function (){var switch__13839__auto__ = ((function (c__13855__auto__,map__19262,map__19262__$1,repositories,local_repo){
return (function (state_19340){
var state_val_19341 = (state_19340[(1)]);
if((state_val_19341 === (7))){
var inst_19282 = (state_19340[(7)]);
var inst_19295 = (state_19340[(8)]);
var inst_19279 = (state_19340[(9)]);
var inst_19292 = (state_19340[(10)]);
var inst_19293 = (state_19340[(11)]);
var inst_19298 = (state_19340[(12)]);
var inst_19280 = (state_19340[(13)]);
var inst_19283 = (state_19340[(14)]);
var inst_19278 = (state_19340[(15)]);
var inst_19297 = (state_19340[(16)]);
var inst_19306 = (state_19340[(17)]);
var inst_19281 = (state_19340[(18)]);
var inst_19300 = (state_19340[(2)]);
var inst_19301 = cljs.core.nth.call(null,inst_19300,(0),null);
var inst_19302 = cljs.core.nth.call(null,inst_19301,(0),null);
var inst_19303 = cljs.core.nth.call(null,inst_19301,(1),null);
var inst_19304 = cljs.core.nth.call(null,inst_19300,(1),null);
var inst_19305 = (function (){var vec__19286 = inst_19300;
var tout = inst_19297;
var no_excl = inst_19292;
var deps = inst_19303;
var repo_reqs = inst_19298;
var urls = inst_19295;
var to_do = inst_19279;
var done = inst_19280;
var exclusions = inst_19282;
var url_set = inst_19293;
var ch = inst_19304;
var locations = inst_19281;
var status = inst_19283;
var next = inst_19278;
var vec__19289 = inst_19301;
var url = inst_19302;
return ((function (vec__19286,tout,no_excl,deps,repo_reqs,urls,to_do,done,exclusions,url_set,ch,locations,status,next,vec__19289,url,inst_19282,inst_19295,inst_19279,inst_19292,inst_19293,inst_19298,inst_19280,inst_19283,inst_19278,inst_19297,inst_19306,inst_19281,inst_19300,inst_19301,inst_19302,inst_19303,inst_19304,state_val_19341,c__13855__auto__,map__19262,map__19262__$1,repositories,local_repo){
return (function (p1__19257_SHARP_){
return !((ch === p1__19257_SHARP_));
});
;})(vec__19286,tout,no_excl,deps,repo_reqs,urls,to_do,done,exclusions,url_set,ch,locations,status,next,vec__19289,url,inst_19282,inst_19295,inst_19279,inst_19292,inst_19293,inst_19298,inst_19280,inst_19283,inst_19278,inst_19297,inst_19306,inst_19281,inst_19300,inst_19301,inst_19302,inst_19303,inst_19304,state_val_19341,c__13855__auto__,map__19262,map__19262__$1,repositories,local_repo))
})();
var inst_19306__$1 = cljs.core.filter.call(null,inst_19305,inst_19298);
var inst_19307 = (function (){var vec__19286 = inst_19300;
var tout = inst_19297;
var to_kill = inst_19306__$1;
var no_excl = inst_19292;
var deps = inst_19303;
var repo_reqs = inst_19298;
var urls = inst_19295;
var to_do = inst_19279;
var done = inst_19280;
var exclusions = inst_19282;
var url_set = inst_19293;
var ch = inst_19304;
var locations = inst_19281;
var status = inst_19283;
var next = inst_19278;
var vec__19289 = inst_19301;
var url = inst_19302;
return ((function (vec__19286,tout,to_kill,no_excl,deps,repo_reqs,urls,to_do,done,exclusions,url_set,ch,locations,status,next,vec__19289,url,inst_19282,inst_19295,inst_19279,inst_19292,inst_19293,inst_19298,inst_19280,inst_19283,inst_19278,inst_19297,inst_19306,inst_19281,inst_19300,inst_19301,inst_19302,inst_19303,inst_19304,inst_19305,inst_19306__$1,state_val_19341,c__13855__auto__,map__19262,map__19262__$1,repositories,local_repo){
return (function (x){
return cljs.core.empty_QMARK_.call(null,cljs.core.filter.call(null,((function (vec__19286,tout,to_kill,no_excl,deps,repo_reqs,urls,to_do,done,exclusions,url_set,ch,locations,status,next,vec__19289,url,inst_19282,inst_19295,inst_19279,inst_19292,inst_19293,inst_19298,inst_19280,inst_19283,inst_19278,inst_19297,inst_19306,inst_19281,inst_19300,inst_19301,inst_19302,inst_19303,inst_19304,inst_19305,inst_19306__$1,state_val_19341,c__13855__auto__,map__19262,map__19262__$1,repositories,local_repo){
return (function (p1__19258_SHARP_){
return (cljs.core._EQ_.call(null,new cljs.core.Keyword(null,"group","group",582596132).cljs$core$IFn$_invoke$arity$1(p1__19258_SHARP_),new cljs.core.Keyword(null,"group","group",582596132).cljs$core$IFn$_invoke$arity$1(x))) && (cljs.core._EQ_.call(null,new cljs.core.Keyword(null,"artifact","artifact",610074681).cljs$core$IFn$_invoke$arity$1(p1__19258_SHARP_),new cljs.core.Keyword(null,"artifact","artifact",610074681).cljs$core$IFn$_invoke$arity$1(x)));
});})(vec__19286,tout,to_kill,no_excl,deps,repo_reqs,urls,to_do,done,exclusions,url_set,ch,locations,status,next,vec__19289,url,inst_19282,inst_19295,inst_19279,inst_19292,inst_19293,inst_19298,inst_19280,inst_19283,inst_19278,inst_19297,inst_19306,inst_19281,inst_19300,inst_19301,inst_19302,inst_19303,inst_19304,inst_19305,inst_19306__$1,state_val_19341,c__13855__auto__,map__19262,map__19262__$1,repositories,local_repo))
,exclusions));
});
;})(vec__19286,tout,to_kill,no_excl,deps,repo_reqs,urls,to_do,done,exclusions,url_set,ch,locations,status,next,vec__19289,url,inst_19282,inst_19295,inst_19279,inst_19292,inst_19293,inst_19298,inst_19280,inst_19283,inst_19278,inst_19297,inst_19306,inst_19281,inst_19300,inst_19301,inst_19302,inst_19303,inst_19304,inst_19305,inst_19306__$1,state_val_19341,c__13855__auto__,map__19262,map__19262__$1,repositories,local_repo))
})();
var inst_19308 = cljs.core.filter.call(null,inst_19307,inst_19303);
var inst_19309 = clojure.set.union.call(null,inst_19279,inst_19308);
var inst_19310 = cljs.core.PersistentHashSet.EMPTY;
var inst_19311 = cljs.core.assoc.call(null,inst_19292,new cljs.core.Keyword(null,"url","url",276297046),inst_19302);
var inst_19312 = cljs.core.conj.call(null,inst_19310,inst_19311);
var inst_19313 = clojure.set.union.call(null,inst_19281,inst_19312);
var inst_19314 = [inst_19292];
var inst_19315 = [inst_19308];
var inst_19316 = cljs.core.PersistentHashMap.fromArrays(inst_19314,inst_19315);
var inst_19317 = cljs.core.into.call(null,inst_19280,inst_19316);
var inst_19318 = (inst_19297 === inst_19304);
var inst_19319 = cljs.core.not.call(null,inst_19318);
var state_19340__$1 = (function (){var statearr_19342 = state_19340;
(statearr_19342[(19)] = inst_19313);

(statearr_19342[(20)] = inst_19317);

(statearr_19342[(17)] = inst_19306__$1);

(statearr_19342[(21)] = inst_19309);

return statearr_19342;
})();
if(inst_19319){
var statearr_19343_19417 = state_19340__$1;
(statearr_19343_19417[(1)] = (8));

} else {
var statearr_19344_19418 = state_19340__$1;
(statearr_19344_19418[(1)] = (9));

}

return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19341 === (1))){
var inst_19274 = cljs.core.PersistentHashSet.EMPTY;
var inst_19275 = cljs.core.PersistentHashMap.EMPTY;
var inst_19276 = cljs.core.PersistentHashSet.EMPTY;
var inst_19277 = new cljs.core.Keyword(null,"exclusions","exclusions",1098729003).cljs$core$IFn$_invoke$arity$1(dep);
var inst_19278 = dep;
var inst_19279 = inst_19274;
var inst_19280 = inst_19275;
var inst_19281 = inst_19276;
var inst_19282 = inst_19277;
var inst_19283 = true;
var state_19340__$1 = (function (){var statearr_19345 = state_19340;
(statearr_19345[(7)] = inst_19282);

(statearr_19345[(9)] = inst_19279);

(statearr_19345[(13)] = inst_19280);

(statearr_19345[(14)] = inst_19283);

(statearr_19345[(15)] = inst_19278);

(statearr_19345[(18)] = inst_19281);

return statearr_19345;
})();
var statearr_19346_19421 = state_19340__$1;
(statearr_19346_19421[(2)] = null);

(statearr_19346_19421[(1)] = (2));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19341 === (4))){
var inst_19282 = (state_19340[(7)]);
var inst_19279 = (state_19340[(9)]);
var inst_19292 = (state_19340[(10)]);
var inst_19293 = (state_19340[(11)]);
var inst_19298 = (state_19340[(12)]);
var inst_19280 = (state_19340[(13)]);
var inst_19283 = (state_19340[(14)]);
var inst_19278 = (state_19340[(15)]);
var inst_19297 = (state_19340[(16)]);
var inst_19281 = (state_19340[(18)]);
var inst_19292__$1 = cljs.core.dissoc.call(null,inst_19278,new cljs.core.Keyword(null,"exclusions","exclusions",1098729003));
var inst_19293__$1 = eginez.huckleberry.core.create_urls_for_dependency.call(null,repositories,inst_19292__$1);
var inst_19294 = (function (){var next = inst_19278;
var to_do = inst_19279;
var done = inst_19280;
var locations = inst_19281;
var exclusions = inst_19282;
var status = inst_19283;
var no_excl = inst_19292__$1;
var url_set = inst_19293__$1;
return ((function (next,to_do,done,locations,exclusions,status,no_excl,url_set,inst_19282,inst_19279,inst_19292,inst_19293,inst_19298,inst_19280,inst_19283,inst_19278,inst_19297,inst_19281,inst_19292__$1,inst_19293__$1,state_val_19341,c__13855__auto__,map__19262,map__19262__$1,repositories,local_repo){
return (function (p1__19256_SHARP_){
return cljs.core.first.call(null,cljs.core.second.call(null,p1__19256_SHARP_));
});
;})(next,to_do,done,locations,exclusions,status,no_excl,url_set,inst_19282,inst_19279,inst_19292,inst_19293,inst_19298,inst_19280,inst_19283,inst_19278,inst_19297,inst_19281,inst_19292__$1,inst_19293__$1,state_val_19341,c__13855__auto__,map__19262,map__19262__$1,repositories,local_repo))
})();
var inst_19295 = cljs.core.map.call(null,inst_19294,inst_19293__$1);
var inst_19296 = eginez.huckleberry.core.extract_dependencies.call(null,inst_19293__$1);
var inst_19297__$1 = cljs.core.async.timeout.call(null,(5000));
var inst_19298__$1 = cljs.core.conj.call(null,inst_19296,inst_19297__$1);
var state_19340__$1 = (function (){var statearr_19347 = state_19340;
(statearr_19347[(8)] = inst_19295);

(statearr_19347[(10)] = inst_19292__$1);

(statearr_19347[(11)] = inst_19293__$1);

(statearr_19347[(12)] = inst_19298__$1);

(statearr_19347[(16)] = inst_19297__$1);

return statearr_19347;
})();
return cljs.core.async.ioc_alts_BANG_.call(null,state_19340__$1,(7),inst_19298__$1);
} else {
if((state_val_19341 === (6))){
var inst_19336 = (state_19340[(2)]);
var state_19340__$1 = state_19340;
var statearr_19348_19423 = state_19340__$1;
(statearr_19348_19423[(2)] = inst_19336);

(statearr_19348_19423[(1)] = (3));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19341 === (3))){
var inst_19338 = (state_19340[(2)]);
var state_19340__$1 = state_19340;
return cljs.core.async.impl.ioc_helpers.return_chan.call(null,state_19340__$1,inst_19338);
} else {
if((state_val_19341 === (2))){
var inst_19278 = (state_19340[(15)]);
var state_19340__$1 = state_19340;
if(cljs.core.truth_(inst_19278)){
var statearr_19350_19424 = state_19340__$1;
(statearr_19350_19424[(1)] = (4));

} else {
var statearr_19351_19425 = state_19340__$1;
(statearr_19351_19425[(1)] = (5));

}

return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19341 === (9))){
var inst_19278 = (state_19340[(15)]);
var inst_19326 = cljs.core.PersistentVector.EMPTY;
var inst_19327 = cljs.core.PersistentVector.EMPTY;
var tmp19349 = inst_19278;
var inst_19278__$1 = null;
var inst_19279 = null;
var inst_19280 = tmp19349;
var inst_19281 = inst_19326;
var inst_19282 = inst_19327;
var inst_19283 = false;
var state_19340__$1 = (function (){var statearr_19352 = state_19340;
(statearr_19352[(7)] = inst_19282);

(statearr_19352[(9)] = inst_19279);

(statearr_19352[(13)] = inst_19280);

(statearr_19352[(14)] = inst_19283);

(statearr_19352[(15)] = inst_19278__$1);

(statearr_19352[(18)] = inst_19281);

return statearr_19352;
})();
var statearr_19353_19429 = state_19340__$1;
(statearr_19353_19429[(2)] = null);

(statearr_19353_19429[(1)] = (2));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19341 === (5))){
var inst_19280 = (state_19340[(13)]);
var inst_19283 = (state_19340[(14)]);
var inst_19281 = (state_19340[(18)]);
var inst_19332 = cljs.core.PersistentVector.EMPTY_NODE;
var inst_19333 = [inst_19283,inst_19280,inst_19281];
var inst_19334 = (new cljs.core.PersistentVector(null,3,(5),inst_19332,inst_19333,null));
var state_19340__$1 = state_19340;
var statearr_19355_19432 = state_19340__$1;
(statearr_19355_19432[(2)] = inst_19334);

(statearr_19355_19432[(1)] = (6));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19341 === (10))){
var inst_19330 = (state_19340[(2)]);
var state_19340__$1 = state_19340;
var statearr_19356_19434 = state_19340__$1;
(statearr_19356_19434[(2)] = inst_19330);

(statearr_19356_19434[(1)] = (6));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19341 === (8))){
var inst_19282 = (state_19340[(7)]);
var inst_19313 = (state_19340[(19)]);
var inst_19317 = (state_19340[(20)]);
var inst_19306 = (state_19340[(17)]);
var inst_19309 = (state_19340[(21)]);
var inst_19321 = cljs.core.map.call(null,cljs.core.async.close_BANG_,inst_19306);
var inst_19322 = cljs.core.first.call(null,inst_19309);
var inst_19323 = cljs.core.rest.call(null,inst_19309);
var tmp19354 = inst_19282;
var inst_19278 = inst_19322;
var inst_19279 = inst_19323;
var inst_19280 = inst_19317;
var inst_19281 = inst_19313;
var inst_19282__$1 = tmp19354;
var inst_19283 = true;
var state_19340__$1 = (function (){var statearr_19357 = state_19340;
(statearr_19357[(22)] = inst_19321);

(statearr_19357[(7)] = inst_19282__$1);

(statearr_19357[(9)] = inst_19279);

(statearr_19357[(13)] = inst_19280);

(statearr_19357[(14)] = inst_19283);

(statearr_19357[(15)] = inst_19278);

(statearr_19357[(18)] = inst_19281);

return statearr_19357;
})();
var statearr_19358_19445 = state_19340__$1;
(statearr_19358_19445[(2)] = null);

(statearr_19358_19445[(1)] = (2));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
return null;
}
}
}
}
}
}
}
}
}
}
});})(c__13855__auto__,map__19262,map__19262__$1,repositories,local_repo))
;
return ((function (switch__13839__auto__,c__13855__auto__,map__19262,map__19262__$1,repositories,local_repo){
return (function() {
var eginez$huckleberry$core$state_machine__13840__auto__ = null;
var eginez$huckleberry$core$state_machine__13840__auto____0 = (function (){
var statearr_19362 = [null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null];
(statearr_19362[(0)] = eginez$huckleberry$core$state_machine__13840__auto__);

(statearr_19362[(1)] = (1));

return statearr_19362;
});
var eginez$huckleberry$core$state_machine__13840__auto____1 = (function (state_19340){
while(true){
var ret_value__13841__auto__ = (function (){try{while(true){
var result__13842__auto__ = switch__13839__auto__.call(null,state_19340);
if(cljs.core.keyword_identical_QMARK_.call(null,result__13842__auto__,new cljs.core.Keyword(null,"recur","recur",-437573268))){
continue;
} else {
return result__13842__auto__;
}
break;
}
}catch (e19363){if((e19363 instanceof Object)){
var ex__13843__auto__ = e19363;
var statearr_19364_19454 = state_19340;
(statearr_19364_19454[(5)] = ex__13843__auto__);


cljs.core.async.impl.ioc_helpers.process_exception.call(null,state_19340);

return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
throw e19363;

}
}})();
if(cljs.core.keyword_identical_QMARK_.call(null,ret_value__13841__auto__,new cljs.core.Keyword(null,"recur","recur",-437573268))){
var G__19457 = state_19340;
state_19340 = G__19457;
continue;
} else {
return ret_value__13841__auto__;
}
break;
}
});
eginez$huckleberry$core$state_machine__13840__auto__ = function(state_19340){
switch(arguments.length){
case 0:
return eginez$huckleberry$core$state_machine__13840__auto____0.call(this);
case 1:
return eginez$huckleberry$core$state_machine__13840__auto____1.call(this,state_19340);
}
throw(new Error('Invalid arity: ' + arguments.length));
};
eginez$huckleberry$core$state_machine__13840__auto__.cljs$core$IFn$_invoke$arity$0 = eginez$huckleberry$core$state_machine__13840__auto____0;
eginez$huckleberry$core$state_machine__13840__auto__.cljs$core$IFn$_invoke$arity$1 = eginez$huckleberry$core$state_machine__13840__auto____1;
return eginez$huckleberry$core$state_machine__13840__auto__;
})()
;})(switch__13839__auto__,c__13855__auto__,map__19262,map__19262__$1,repositories,local_repo))
})();
var state__13857__auto__ = (function (){var statearr_19365 = f__13856__auto__.call(null);
(statearr_19365[cljs.core.async.impl.ioc_helpers.USER_START_IDX] = c__13855__auto__);

return statearr_19365;
})();
return cljs.core.async.impl.ioc_helpers.run_state_machine_wrapped.call(null,state__13857__auto__);
});})(c__13855__auto__,map__19262,map__19262__$1,repositories,local_repo))
);

return c__13855__auto__;
});

eginez.huckleberry.core.resolve.cljs$lang$maxFixedArity = (1);

eginez.huckleberry.core.resolve.cljs$lang$applyTo = (function (seq19259){
var G__19260 = cljs.core.first.call(null,seq19259);
var seq19259__$1 = cljs.core.next.call(null,seq19259);
return eginez.huckleberry.core.resolve.cljs$core$IFn$_invoke$arity$variadic(G__19260,seq19259__$1);
});

eginez.huckleberry.core.resolve_all = (function eginez$huckleberry$core$resolve_all(var_args){
var args__7658__auto__ = [];
var len__7651__auto___19538 = arguments.length;
var i__7652__auto___19539 = (0);
while(true){
if((i__7652__auto___19539 < len__7651__auto___19538)){
args__7658__auto__.push((arguments[i__7652__auto___19539]));

var G__19540 = (i__7652__auto___19539 + (1));
i__7652__auto___19539 = G__19540;
continue;
} else {
}
break;
}

var argseq__7659__auto__ = ((((1) < args__7658__auto__.length))?(new cljs.core.IndexedSeq(args__7658__auto__.slice((1)),(0),null)):null);
return eginez.huckleberry.core.resolve_all.cljs$core$IFn$_invoke$arity$variadic((arguments[(0)]),argseq__7659__auto__);
});

eginez.huckleberry.core.resolve_all.cljs$core$IFn$_invoke$arity$variadic = (function (all_deps,opts){
var c__13855__auto__ = cljs.core.async.chan.call(null,(1));
cljs.core.async.impl.dispatch.run.call(null,((function (c__13855__auto__){
return (function (){
var f__13856__auto__ = (function (){var switch__13839__auto__ = ((function (c__13855__auto__){
return (function (state_19500){
var state_val_19501 = (state_19500[(1)]);
if((state_val_19501 === (7))){
var inst_19465 = (state_19500[(7)]);
var inst_19480 = (state_19500[(8)]);
var inst_19480__$1 = cljs.core.first.call(null,inst_19465);
var inst_19481 = cljs.core.apply.call(null,eginez.huckleberry.core.resolve,inst_19480__$1,opts);
var state_19500__$1 = (function (){var statearr_19505 = state_19500;
(statearr_19505[(8)] = inst_19480__$1);

return statearr_19505;
})();
return cljs.core.async.impl.ioc_helpers.take_BANG_.call(null,state_19500__$1,(10),inst_19481);
} else {
if((state_val_19501 === (1))){
var inst_19463 = cljs.core.PersistentVector.EMPTY;
var inst_19464 = cljs.core.PersistentHashSet.EMPTY;
var inst_19465 = all_deps;
var inst_19466 = inst_19463;
var inst_19467 = inst_19464;
var inst_19468 = true;
var state_19500__$1 = (function (){var statearr_19506 = state_19500;
(statearr_19506[(9)] = inst_19467);

(statearr_19506[(7)] = inst_19465);

(statearr_19506[(10)] = inst_19466);

(statearr_19506[(11)] = inst_19468);

return statearr_19506;
})();
var statearr_19507_19544 = state_19500__$1;
(statearr_19507_19544[(2)] = null);

(statearr_19507_19544[(1)] = (2));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19501 === (4))){
var inst_19465 = (state_19500[(7)]);
var inst_19471 = cljs.core.empty_QMARK_.call(null,inst_19465);
var inst_19472 = !(inst_19471);
var state_19500__$1 = state_19500;
var statearr_19508_19551 = state_19500__$1;
(statearr_19508_19551[(2)] = inst_19472);

(statearr_19508_19551[(1)] = (6));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19501 === (6))){
var inst_19475 = (state_19500[(2)]);
var state_19500__$1 = state_19500;
if(cljs.core.truth_(inst_19475)){
var statearr_19511_19555 = state_19500__$1;
(statearr_19511_19555[(1)] = (7));

} else {
var statearr_19512_19556 = state_19500__$1;
(statearr_19512_19556[(1)] = (8));

}

return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19501 === (3))){
var inst_19498 = (state_19500[(2)]);
var state_19500__$1 = state_19500;
return cljs.core.async.impl.ioc_helpers.return_chan.call(null,state_19500__$1,inst_19498);
} else {
if((state_val_19501 === (2))){
var inst_19468 = (state_19500[(11)]);
var state_19500__$1 = state_19500;
if(cljs.core.truth_(inst_19468)){
var statearr_19513_19557 = state_19500__$1;
(statearr_19513_19557[(1)] = (4));

} else {
var statearr_19516_19558 = state_19500__$1;
(statearr_19516_19558[(1)] = (5));

}

return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19501 === (9))){
var inst_19496 = (state_19500[(2)]);
var state_19500__$1 = state_19500;
var statearr_19518_19559 = state_19500__$1;
(statearr_19518_19559[(2)] = inst_19496);

(statearr_19518_19559[(1)] = (3));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19501 === (5))){
var inst_19468 = (state_19500[(11)]);
var state_19500__$1 = state_19500;
var statearr_19519_19562 = state_19500__$1;
(statearr_19519_19562[(2)] = inst_19468);

(statearr_19519_19562[(1)] = (6));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19501 === (10))){
var inst_19467 = (state_19500[(9)]);
var inst_19465 = (state_19500[(7)]);
var inst_19466 = (state_19500[(10)]);
var inst_19480 = (state_19500[(8)]);
var inst_19483 = (state_19500[(2)]);
var inst_19484 = cljs.core.nth.call(null,inst_19483,(0),null);
var inst_19485 = cljs.core.nth.call(null,inst_19483,(1),null);
var inst_19486 = cljs.core.nth.call(null,inst_19483,(2),null);
var inst_19487 = cljs.core.conj.call(null,inst_19466,inst_19480,inst_19485);
var inst_19488 = cljs.core.rest.call(null,inst_19465);
var inst_19489 = clojure.set.union.call(null,inst_19467,inst_19486);
var inst_19465__$1 = inst_19488;
var inst_19466__$1 = inst_19487;
var inst_19467__$1 = inst_19489;
var inst_19468 = inst_19484;
var state_19500__$1 = (function (){var statearr_19522 = state_19500;
(statearr_19522[(9)] = inst_19467__$1);

(statearr_19522[(7)] = inst_19465__$1);

(statearr_19522[(10)] = inst_19466__$1);

(statearr_19522[(11)] = inst_19468);

return statearr_19522;
})();
var statearr_19523_19569 = state_19500__$1;
(statearr_19523_19569[(2)] = null);

(statearr_19523_19569[(1)] = (2));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19501 === (8))){
var inst_19467 = (state_19500[(9)]);
var inst_19466 = (state_19500[(10)]);
var inst_19468 = (state_19500[(11)]);
var inst_19492 = cljs.core.PersistentVector.EMPTY_NODE;
var inst_19493 = [inst_19468,inst_19466,inst_19467];
var inst_19494 = (new cljs.core.PersistentVector(null,3,(5),inst_19492,inst_19493,null));
var state_19500__$1 = state_19500;
var statearr_19526_19572 = state_19500__$1;
(statearr_19526_19572[(2)] = inst_19494);

(statearr_19526_19572[(1)] = (9));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
return null;
}
}
}
}
}
}
}
}
}
}
});})(c__13855__auto__))
;
return ((function (switch__13839__auto__,c__13855__auto__){
return (function() {
var eginez$huckleberry$core$state_machine__13840__auto__ = null;
var eginez$huckleberry$core$state_machine__13840__auto____0 = (function (){
var statearr_19534 = [null,null,null,null,null,null,null,null,null,null,null,null];
(statearr_19534[(0)] = eginez$huckleberry$core$state_machine__13840__auto__);

(statearr_19534[(1)] = (1));

return statearr_19534;
});
var eginez$huckleberry$core$state_machine__13840__auto____1 = (function (state_19500){
while(true){
var ret_value__13841__auto__ = (function (){try{while(true){
var result__13842__auto__ = switch__13839__auto__.call(null,state_19500);
if(cljs.core.keyword_identical_QMARK_.call(null,result__13842__auto__,new cljs.core.Keyword(null,"recur","recur",-437573268))){
continue;
} else {
return result__13842__auto__;
}
break;
}
}catch (e19535){if((e19535 instanceof Object)){
var ex__13843__auto__ = e19535;
var statearr_19536_19576 = state_19500;
(statearr_19536_19576[(5)] = ex__13843__auto__);


cljs.core.async.impl.ioc_helpers.process_exception.call(null,state_19500);

return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
throw e19535;

}
}})();
if(cljs.core.keyword_identical_QMARK_.call(null,ret_value__13841__auto__,new cljs.core.Keyword(null,"recur","recur",-437573268))){
var G__19578 = state_19500;
state_19500 = G__19578;
continue;
} else {
return ret_value__13841__auto__;
}
break;
}
});
eginez$huckleberry$core$state_machine__13840__auto__ = function(state_19500){
switch(arguments.length){
case 0:
return eginez$huckleberry$core$state_machine__13840__auto____0.call(this);
case 1:
return eginez$huckleberry$core$state_machine__13840__auto____1.call(this,state_19500);
}
throw(new Error('Invalid arity: ' + arguments.length));
};
eginez$huckleberry$core$state_machine__13840__auto__.cljs$core$IFn$_invoke$arity$0 = eginez$huckleberry$core$state_machine__13840__auto____0;
eginez$huckleberry$core$state_machine__13840__auto__.cljs$core$IFn$_invoke$arity$1 = eginez$huckleberry$core$state_machine__13840__auto____1;
return eginez$huckleberry$core$state_machine__13840__auto__;
})()
;})(switch__13839__auto__,c__13855__auto__))
})();
var state__13857__auto__ = (function (){var statearr_19537 = f__13856__auto__.call(null);
(statearr_19537[cljs.core.async.impl.ioc_helpers.USER_START_IDX] = c__13855__auto__);

return statearr_19537;
})();
return cljs.core.async.impl.ioc_helpers.run_state_machine_wrapped.call(null,state__13857__auto__);
});})(c__13855__auto__))
);

return c__13855__auto__;
});

eginez.huckleberry.core.resolve_all.cljs$lang$maxFixedArity = (1);

eginez.huckleberry.core.resolve_all.cljs$lang$applyTo = (function (seq19458){
var G__19459 = cljs.core.first.call(null,seq19458);
var seq19458__$1 = cljs.core.next.call(null,seq19458);
return eginez.huckleberry.core.resolve_all.cljs$core$IFn$_invoke$arity$variadic(G__19459,seq19458__$1);
});

eginez.huckleberry.core.group = (function eginez$huckleberry$core$group(group_artifact){
var or__6543__auto__ = cljs.core.namespace.call(null,group_artifact);
if(cljs.core.truth_(or__6543__auto__)){
return or__6543__auto__;
} else {
return cljs.core.name.call(null,group_artifact);
}
});
eginez.huckleberry.core.exclusion = (function eginez$huckleberry$core$exclusion(p__19581){
var vec__19591 = p__19581;
var seq__19592 = cljs.core.seq.call(null,vec__19591);
var first__19593 = cljs.core.first.call(null,seq__19592);
var seq__19592__$1 = cljs.core.next.call(null,seq__19592);
var group_artifact = first__19593;
var map__19594 = seq__19592__$1;
var map__19594__$1 = ((((!((map__19594 == null)))?((((map__19594.cljs$lang$protocol_mask$partition0$ & (64))) || ((cljs.core.PROTOCOL_SENTINEL === map__19594.cljs$core$ISeq$)))?true:false):false))?cljs.core.apply.call(null,cljs.core.hash_map,map__19594):map__19594);
var opts = map__19594__$1;
return new cljs.core.PersistentArrayMap(null, 4, [new cljs.core.Keyword(null,"group","group",582596132),eginez.huckleberry.core.group.call(null,group_artifact),new cljs.core.Keyword(null,"artifact","artifact",610074681),cljs.core.name.call(null,group_artifact),new cljs.core.Keyword(null,"classifier","classifier",-864028247),new cljs.core.Keyword(null,"classifier","classifier",-864028247).cljs$core$IFn$_invoke$arity$2(opts,"*"),new cljs.core.Keyword(null,"extension","extension",1453374065),new cljs.core.Keyword(null,"extension","extension",1453374065).cljs$core$IFn$_invoke$arity$2(opts,"*")], null);
});
eginez.huckleberry.core.normalize_exclusion_spec = (function eginez$huckleberry$core$normalize_exclusion_spec(spec){
if((spec instanceof cljs.core.Symbol)){
return new cljs.core.PersistentVector(null, 1, 5, cljs.core.PersistentVector.EMPTY_NODE, [spec], null);
} else {
return spec;
}
});
eginez.huckleberry.core.dependency = (function eginez$huckleberry$core$dependency(p__19612){
var vec__19623 = p__19612;
var seq__19624 = cljs.core.seq.call(null,vec__19623);
var first__19625 = cljs.core.first.call(null,seq__19624);
var seq__19624__$1 = cljs.core.next.call(null,seq__19624);
var group_artifact = first__19625;
var first__19625__$1 = cljs.core.first.call(null,seq__19624__$1);
var seq__19624__$2 = cljs.core.next.call(null,seq__19624__$1);
var version = first__19625__$1;
var map__19626 = seq__19624__$2;
var map__19626__$1 = ((((!((map__19626 == null)))?((((map__19626.cljs$lang$protocol_mask$partition0$ & (64))) || ((cljs.core.PROTOCOL_SENTINEL === map__19626.cljs$core$ISeq$)))?true:false):false))?cljs.core.apply.call(null,cljs.core.hash_map,map__19626):map__19626);
var opts = map__19626__$1;
var scope = cljs.core.get.call(null,map__19626__$1,new cljs.core.Keyword(null,"scope","scope",-439358418),"compile");
var optional = cljs.core.get.call(null,map__19626__$1,new cljs.core.Keyword(null,"optional","optional",2053951509),false);
var exclusions = cljs.core.get.call(null,map__19626__$1,new cljs.core.Keyword(null,"exclusions","exclusions",1098729003));
var dep_spec = vec__19623;
return new cljs.core.PersistentArrayMap(null, 4, [new cljs.core.Keyword(null,"group","group",582596132),eginez.huckleberry.core.group.call(null,group_artifact),new cljs.core.Keyword(null,"artifact","artifact",610074681),cljs.core.name.call(null,group_artifact),new cljs.core.Keyword(null,"version","version",425292698),version,new cljs.core.Keyword(null,"exclusions","exclusions",1098729003),cljs.core.map.call(null,cljs.core.comp.call(null,eginez.huckleberry.core.exclusion,eginez.huckleberry.core.normalize_exclusion_spec),exclusions)], null);
});
eginez.huckleberry.core.download_and_save_pipeline = (function eginez$huckleberry$core$download_and_save_pipeline(p__19652){
var vec__19660 = p__19652;
var download_from = cljs.core.nth.call(null,vec__19660,(0),null);
var save_to = cljs.core.nth.call(null,vec__19660,(1),null);
var c = cljs.core.async.chan.call(null,(1024),cljs.core.comp.call(null,cljs.core.map.call(null,((function (vec__19660,download_from,save_to){
return (function (p1__19651_SHARP_){
return eginez.huckleberry.os.write_file.call(null,save_to,p1__19651_SHARP_);
});})(vec__19660,download_from,save_to))
)));
return eginez.huckleberry.os.make_http_request.call(null,c,download_from);
});
eginez.huckleberry.core.retrieve = (function eginez$huckleberry$core$retrieve(dep,in_repo){
var repo_url = new cljs.core.Keyword(null,"url","url",276297046).cljs$core$IFn$_invoke$arity$1(dep);
var urls = eginez.huckleberry.core.create_urls_for_dependency.call(null,repo_url,dep);
var save_to_locations = eginez.huckleberry.core.create_urls_for_dependency.call(null,in_repo,dep);
var urls_to_proc = cljs.core.map.call(null,cljs.core.vector,cljs.core.second.call(null,urls),cljs.core.second.call(null,save_to_locations));
var local_deps = cljs.core.assoc.call(null,dep,new cljs.core.Keyword(null,"url","url",276297046),in_repo);
var c_jar = eginez.huckleberry.core.download_and_save_pipeline.call(null,cljs.core.second.call(null,urls_to_proc));
var c_pom = eginez.huckleberry.core.download_and_save_pipeline.call(null,cljs.core.first.call(null,urls_to_proc));
var c__13855__auto__ = cljs.core.async.chan.call(null,(1));
cljs.core.async.impl.dispatch.run.call(null,((function (c__13855__auto__,repo_url,urls,save_to_locations,urls_to_proc,local_deps,c_jar,c_pom){
return (function (){
var f__13856__auto__ = (function (){var switch__13839__auto__ = ((function (c__13855__auto__,repo_url,urls,save_to_locations,urls_to_proc,local_deps,c_jar,c_pom){
return (function (state_19703){
var state_val_19704 = (state_19703[(1)]);
if((state_val_19704 === (1))){
var inst_19695 = cljs.core.second.call(null,urls_to_proc);
var inst_19696 = cljs.core.first.call(null,inst_19695);
var inst_19697 = cljs.core.println.call(null,"Downloading",inst_19696);
var state_19703__$1 = (function (){var statearr_19706 = state_19703;
(statearr_19706[(7)] = inst_19697);

return statearr_19706;
})();
return cljs.core.async.impl.ioc_helpers.take_BANG_.call(null,state_19703__$1,(2),c_jar);
} else {
if((state_val_19704 === (2))){
var inst_19699 = (state_19703[(2)]);
var state_19703__$1 = (function (){var statearr_19709 = state_19703;
(statearr_19709[(8)] = inst_19699);

return statearr_19709;
})();
return cljs.core.async.impl.ioc_helpers.take_BANG_.call(null,state_19703__$1,(3),c_pom);
} else {
if((state_val_19704 === (3))){
var inst_19701 = (state_19703[(2)]);
var state_19703__$1 = (function (){var statearr_19712 = state_19703;
(statearr_19712[(9)] = inst_19701);

return statearr_19712;
})();
return cljs.core.async.impl.ioc_helpers.return_chan.call(null,state_19703__$1,local_deps);
} else {
return null;
}
}
}
});})(c__13855__auto__,repo_url,urls,save_to_locations,urls_to_proc,local_deps,c_jar,c_pom))
;
return ((function (switch__13839__auto__,c__13855__auto__,repo_url,urls,save_to_locations,urls_to_proc,local_deps,c_jar,c_pom){
return (function() {
var eginez$huckleberry$core$retrieve_$_state_machine__13840__auto__ = null;
var eginez$huckleberry$core$retrieve_$_state_machine__13840__auto____0 = (function (){
var statearr_19717 = [null,null,null,null,null,null,null,null,null,null];
(statearr_19717[(0)] = eginez$huckleberry$core$retrieve_$_state_machine__13840__auto__);

(statearr_19717[(1)] = (1));

return statearr_19717;
});
var eginez$huckleberry$core$retrieve_$_state_machine__13840__auto____1 = (function (state_19703){
while(true){
var ret_value__13841__auto__ = (function (){try{while(true){
var result__13842__auto__ = switch__13839__auto__.call(null,state_19703);
if(cljs.core.keyword_identical_QMARK_.call(null,result__13842__auto__,new cljs.core.Keyword(null,"recur","recur",-437573268))){
continue;
} else {
return result__13842__auto__;
}
break;
}
}catch (e19719){if((e19719 instanceof Object)){
var ex__13843__auto__ = e19719;
var statearr_19720_19752 = state_19703;
(statearr_19720_19752[(5)] = ex__13843__auto__);


cljs.core.async.impl.ioc_helpers.process_exception.call(null,state_19703);

return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
throw e19719;

}
}})();
if(cljs.core.keyword_identical_QMARK_.call(null,ret_value__13841__auto__,new cljs.core.Keyword(null,"recur","recur",-437573268))){
var G__19753 = state_19703;
state_19703 = G__19753;
continue;
} else {
return ret_value__13841__auto__;
}
break;
}
});
eginez$huckleberry$core$retrieve_$_state_machine__13840__auto__ = function(state_19703){
switch(arguments.length){
case 0:
return eginez$huckleberry$core$retrieve_$_state_machine__13840__auto____0.call(this);
case 1:
return eginez$huckleberry$core$retrieve_$_state_machine__13840__auto____1.call(this,state_19703);
}
throw(new Error('Invalid arity: ' + arguments.length));
};
eginez$huckleberry$core$retrieve_$_state_machine__13840__auto__.cljs$core$IFn$_invoke$arity$0 = eginez$huckleberry$core$retrieve_$_state_machine__13840__auto____0;
eginez$huckleberry$core$retrieve_$_state_machine__13840__auto__.cljs$core$IFn$_invoke$arity$1 = eginez$huckleberry$core$retrieve_$_state_machine__13840__auto____1;
return eginez$huckleberry$core$retrieve_$_state_machine__13840__auto__;
})()
;})(switch__13839__auto__,c__13855__auto__,repo_url,urls,save_to_locations,urls_to_proc,local_deps,c_jar,c_pom))
})();
var state__13857__auto__ = (function (){var statearr_19724 = f__13856__auto__.call(null);
(statearr_19724[cljs.core.async.impl.ioc_helpers.USER_START_IDX] = c__13855__auto__);

return statearr_19724;
})();
return cljs.core.async.impl.ioc_helpers.run_state_machine_wrapped.call(null,state__13857__auto__);
});})(c__13855__auto__,repo_url,urls,save_to_locations,urls_to_proc,local_deps,c_jar,c_pom))
);

return c__13855__auto__;
});
eginez.huckleberry.core.retrieve_all = (function eginez$huckleberry$core$retrieve_all(local_deps,to_do,in_repo){
var c__13855__auto__ = cljs.core.async.chan.call(null,(1));
cljs.core.async.impl.dispatch.run.call(null,((function (c__13855__auto__){
return (function (){
var f__13856__auto__ = (function (){var switch__13839__auto__ = ((function (c__13855__auto__){
return (function (state_19815){
var state_val_19816 = (state_19815[(1)]);
if((state_val_19816 === (1))){
var inst_19796 = local_deps;
var inst_19797 = to_do;
var inst_19798 = in_repo;
var state_19815__$1 = (function (){var statearr_19818 = state_19815;
(statearr_19818[(7)] = inst_19796);

(statearr_19818[(8)] = inst_19797);

(statearr_19818[(9)] = inst_19798);

return statearr_19818;
})();
var statearr_19819_19847 = state_19815__$1;
(statearr_19819_19847[(2)] = null);

(statearr_19819_19847[(1)] = (2));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19816 === (2))){
var inst_19797 = (state_19815[(8)]);
var inst_19800 = cljs.core.empty_QMARK_.call(null,inst_19797);
var state_19815__$1 = state_19815;
if(inst_19800){
var statearr_19821_19857 = state_19815__$1;
(statearr_19821_19857[(1)] = (4));

} else {
var statearr_19822_19858 = state_19815__$1;
(statearr_19822_19858[(1)] = (5));

}

return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19816 === (3))){
var inst_19813 = (state_19815[(2)]);
var state_19815__$1 = state_19815;
return cljs.core.async.impl.ioc_helpers.return_chan.call(null,state_19815__$1,inst_19813);
} else {
if((state_val_19816 === (4))){
var inst_19796 = (state_19815[(7)]);
var state_19815__$1 = state_19815;
var statearr_19823_19863 = state_19815__$1;
(statearr_19823_19863[(2)] = inst_19796);

(statearr_19823_19863[(1)] = (6));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19816 === (5))){
var inst_19797 = (state_19815[(8)]);
var inst_19803 = cljs.core.first.call(null,inst_19797);
var inst_19804 = eginez.huckleberry.core.retrieve.call(null,inst_19803,in_repo);
var state_19815__$1 = state_19815;
return cljs.core.async.impl.ioc_helpers.take_BANG_.call(null,state_19815__$1,(7),inst_19804);
} else {
if((state_val_19816 === (6))){
var inst_19811 = (state_19815[(2)]);
var state_19815__$1 = state_19815;
var statearr_19825_19864 = state_19815__$1;
(statearr_19825_19864[(2)] = inst_19811);

(statearr_19825_19864[(1)] = (3));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19816 === (7))){
var inst_19796 = (state_19815[(7)]);
var inst_19797 = (state_19815[(8)]);
var inst_19806 = (state_19815[(2)]);
var inst_19807 = cljs.core.conj.call(null,inst_19796,inst_19806);
var inst_19808 = cljs.core.rest.call(null,inst_19797);
var inst_19796__$1 = inst_19807;
var inst_19797__$1 = inst_19808;
var inst_19798 = in_repo;
var state_19815__$1 = (function (){var statearr_19826 = state_19815;
(statearr_19826[(7)] = inst_19796__$1);

(statearr_19826[(8)] = inst_19797__$1);

(statearr_19826[(9)] = inst_19798);

return statearr_19826;
})();
var statearr_19828_19865 = state_19815__$1;
(statearr_19828_19865[(2)] = null);

(statearr_19828_19865[(1)] = (2));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
return null;
}
}
}
}
}
}
}
});})(c__13855__auto__))
;
return ((function (switch__13839__auto__,c__13855__auto__){
return (function() {
var eginez$huckleberry$core$retrieve_all_$_state_machine__13840__auto__ = null;
var eginez$huckleberry$core$retrieve_all_$_state_machine__13840__auto____0 = (function (){
var statearr_19832 = [null,null,null,null,null,null,null,null,null,null];
(statearr_19832[(0)] = eginez$huckleberry$core$retrieve_all_$_state_machine__13840__auto__);

(statearr_19832[(1)] = (1));

return statearr_19832;
});
var eginez$huckleberry$core$retrieve_all_$_state_machine__13840__auto____1 = (function (state_19815){
while(true){
var ret_value__13841__auto__ = (function (){try{while(true){
var result__13842__auto__ = switch__13839__auto__.call(null,state_19815);
if(cljs.core.keyword_identical_QMARK_.call(null,result__13842__auto__,new cljs.core.Keyword(null,"recur","recur",-437573268))){
continue;
} else {
return result__13842__auto__;
}
break;
}
}catch (e19833){if((e19833 instanceof Object)){
var ex__13843__auto__ = e19833;
var statearr_19834_19869 = state_19815;
(statearr_19834_19869[(5)] = ex__13843__auto__);


cljs.core.async.impl.ioc_helpers.process_exception.call(null,state_19815);

return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
throw e19833;

}
}})();
if(cljs.core.keyword_identical_QMARK_.call(null,ret_value__13841__auto__,new cljs.core.Keyword(null,"recur","recur",-437573268))){
var G__19871 = state_19815;
state_19815 = G__19871;
continue;
} else {
return ret_value__13841__auto__;
}
break;
}
});
eginez$huckleberry$core$retrieve_all_$_state_machine__13840__auto__ = function(state_19815){
switch(arguments.length){
case 0:
return eginez$huckleberry$core$retrieve_all_$_state_machine__13840__auto____0.call(this);
case 1:
return eginez$huckleberry$core$retrieve_all_$_state_machine__13840__auto____1.call(this,state_19815);
}
throw(new Error('Invalid arity: ' + arguments.length));
};
eginez$huckleberry$core$retrieve_all_$_state_machine__13840__auto__.cljs$core$IFn$_invoke$arity$0 = eginez$huckleberry$core$retrieve_all_$_state_machine__13840__auto____0;
eginez$huckleberry$core$retrieve_all_$_state_machine__13840__auto__.cljs$core$IFn$_invoke$arity$1 = eginez$huckleberry$core$retrieve_all_$_state_machine__13840__auto____1;
return eginez$huckleberry$core$retrieve_all_$_state_machine__13840__auto__;
})()
;})(switch__13839__auto__,c__13855__auto__))
})();
var state__13857__auto__ = (function (){var statearr_19844 = f__13856__auto__.call(null);
(statearr_19844[cljs.core.async.impl.ioc_helpers.USER_START_IDX] = c__13855__auto__);

return statearr_19844;
})();
return cljs.core.async.impl.ioc_helpers.run_state_machine_wrapped.call(null,state__13857__auto__);
});})(c__13855__auto__))
);

return c__13855__auto__;
});
eginez.huckleberry.core.retrieve_dependencies = (function eginez$huckleberry$core$retrieve_dependencies(p__19878,local_repo,offline_QMARK_){
var vec__19899 = p__19878;
var _ = cljs.core.nth.call(null,vec__19899,(0),null);
var ___$1 = cljs.core.nth.call(null,vec__19899,(1),null);
var dep_list = cljs.core.nth.call(null,vec__19899,(2),null);
var local_deps = cljs.core.filter.call(null,((function (vec__19899,_,___$1,dep_list){
return (function (p1__19876_SHARP_){
return eginez.huckleberry.core.is_url_local_QMARK_.call(null,new cljs.core.Keyword(null,"url","url",276297046).cljs$core$IFn$_invoke$arity$1(p1__19876_SHARP_));
});})(vec__19899,_,___$1,dep_list))
,dep_list);
var remote_deps = cljs.core.filter.call(null,((function (local_deps,vec__19899,_,___$1,dep_list){
return (function (p1__19877_SHARP_){
return cljs.core.not.call(null,eginez.huckleberry.core.is_url_local_QMARK_.call(null,new cljs.core.Keyword(null,"url","url",276297046).cljs$core$IFn$_invoke$arity$1(p1__19877_SHARP_)));
});})(local_deps,vec__19899,_,___$1,dep_list))
,dep_list);
if(cljs.core.truth_((function (){var and__6531__auto__ = offline_QMARK_;
if(cljs.core.truth_(and__6531__auto__)){
return (local_repo == null);
} else {
return and__6531__auto__;
}
})())){
return null;
} else {
if(cljs.core.empty_QMARK_.call(null,remote_deps)){
var c__13855__auto__ = cljs.core.async.chan.call(null,(1));
cljs.core.async.impl.dispatch.run.call(null,((function (c__13855__auto__,local_deps,remote_deps,vec__19899,_,___$1,dep_list){
return (function (){
var f__13856__auto__ = (function (){var switch__13839__auto__ = ((function (c__13855__auto__,local_deps,remote_deps,vec__19899,_,___$1,dep_list){
return (function (state_19903){
var state_val_19904 = (state_19903[(1)]);
if((state_val_19904 === (1))){
var state_19903__$1 = state_19903;
return cljs.core.async.impl.ioc_helpers.return_chan.call(null,state_19903__$1,dep_list);
} else {
return null;
}
});})(c__13855__auto__,local_deps,remote_deps,vec__19899,_,___$1,dep_list))
;
return ((function (switch__13839__auto__,c__13855__auto__,local_deps,remote_deps,vec__19899,_,___$1,dep_list){
return (function() {
var eginez$huckleberry$core$retrieve_dependencies_$_state_machine__13840__auto__ = null;
var eginez$huckleberry$core$retrieve_dependencies_$_state_machine__13840__auto____0 = (function (){
var statearr_19908 = [null,null,null,null,null,null,null];
(statearr_19908[(0)] = eginez$huckleberry$core$retrieve_dependencies_$_state_machine__13840__auto__);

(statearr_19908[(1)] = (1));

return statearr_19908;
});
var eginez$huckleberry$core$retrieve_dependencies_$_state_machine__13840__auto____1 = (function (state_19903){
while(true){
var ret_value__13841__auto__ = (function (){try{while(true){
var result__13842__auto__ = switch__13839__auto__.call(null,state_19903);
if(cljs.core.keyword_identical_QMARK_.call(null,result__13842__auto__,new cljs.core.Keyword(null,"recur","recur",-437573268))){
continue;
} else {
return result__13842__auto__;
}
break;
}
}catch (e19909){if((e19909 instanceof Object)){
var ex__13843__auto__ = e19909;
var statearr_19911_19930 = state_19903;
(statearr_19911_19930[(5)] = ex__13843__auto__);


cljs.core.async.impl.ioc_helpers.process_exception.call(null,state_19903);

return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
throw e19909;

}
}})();
if(cljs.core.keyword_identical_QMARK_.call(null,ret_value__13841__auto__,new cljs.core.Keyword(null,"recur","recur",-437573268))){
var G__19932 = state_19903;
state_19903 = G__19932;
continue;
} else {
return ret_value__13841__auto__;
}
break;
}
});
eginez$huckleberry$core$retrieve_dependencies_$_state_machine__13840__auto__ = function(state_19903){
switch(arguments.length){
case 0:
return eginez$huckleberry$core$retrieve_dependencies_$_state_machine__13840__auto____0.call(this);
case 1:
return eginez$huckleberry$core$retrieve_dependencies_$_state_machine__13840__auto____1.call(this,state_19903);
}
throw(new Error('Invalid arity: ' + arguments.length));
};
eginez$huckleberry$core$retrieve_dependencies_$_state_machine__13840__auto__.cljs$core$IFn$_invoke$arity$0 = eginez$huckleberry$core$retrieve_dependencies_$_state_machine__13840__auto____0;
eginez$huckleberry$core$retrieve_dependencies_$_state_machine__13840__auto__.cljs$core$IFn$_invoke$arity$1 = eginez$huckleberry$core$retrieve_dependencies_$_state_machine__13840__auto____1;
return eginez$huckleberry$core$retrieve_dependencies_$_state_machine__13840__auto__;
})()
;})(switch__13839__auto__,c__13855__auto__,local_deps,remote_deps,vec__19899,_,___$1,dep_list))
})();
var state__13857__auto__ = (function (){var statearr_19912 = f__13856__auto__.call(null);
(statearr_19912[cljs.core.async.impl.ioc_helpers.USER_START_IDX] = c__13855__auto__);

return statearr_19912;
})();
return cljs.core.async.impl.ioc_helpers.run_state_machine_wrapped.call(null,state__13857__auto__);
});})(c__13855__auto__,local_deps,remote_deps,vec__19899,_,___$1,dep_list))
);

return c__13855__auto__;
} else {
return eginez.huckleberry.core.retrieve_all.call(null,local_deps,remote_deps,local_repo);
}
}
});
eginez.huckleberry.core.resolve_dependencies = (function eginez$huckleberry$core$resolve_dependencies(var_args){
var args__7658__auto__ = [];
var len__7651__auto___20010 = arguments.length;
var i__7652__auto___20011 = (0);
while(true){
if((i__7652__auto___20011 < len__7651__auto___20010)){
args__7658__auto__.push((arguments[i__7652__auto___20011]));

var G__20021 = (i__7652__auto___20011 + (1));
i__7652__auto___20011 = G__20021;
continue;
} else {
}
break;
}

var argseq__7659__auto__ = ((((0) < args__7658__auto__.length))?(new cljs.core.IndexedSeq(args__7658__auto__.slice((0)),(0),null)):null);
return eginez.huckleberry.core.resolve_dependencies.cljs$core$IFn$_invoke$arity$variadic(argseq__7659__auto__);
});

eginez.huckleberry.core.resolve_dependencies.cljs$core$IFn$_invoke$arity$variadic = (function (p__19940){
var map__19941 = p__19940;
var map__19941__$1 = ((((!((map__19941 == null)))?((((map__19941.cljs$lang$protocol_mask$partition0$ & (64))) || ((cljs.core.PROTOCOL_SENTINEL === map__19941.cljs$core$ISeq$)))?true:false):false))?cljs.core.apply.call(null,cljs.core.hash_map,map__19941):map__19941);
var repositories = cljs.core.get.call(null,map__19941__$1,new cljs.core.Keyword(null,"repositories","repositories",1367837581));
var coordinates = cljs.core.get.call(null,map__19941__$1,new cljs.core.Keyword(null,"coordinates","coordinates",-1225332668));
var retrieve = cljs.core.get.call(null,map__19941__$1,new cljs.core.Keyword(null,"retrieve","retrieve",-657129560),true);
var local_repo = cljs.core.get.call(null,map__19941__$1,new cljs.core.Keyword(null,"local-repo","local-repo",764410280));
var proxy = cljs.core.get.call(null,map__19941__$1,new cljs.core.Keyword(null,"proxy","proxy",-117453614));
var mirrors = cljs.core.get.call(null,map__19941__$1,new cljs.core.Keyword(null,"mirrors","mirrors",-747507693));
var managed_coordinates = cljs.core.get.call(null,map__19941__$1,new cljs.core.Keyword(null,"managed-coordinates","managed-coordinates",369843210));
var c__13855__auto__ = cljs.core.async.chan.call(null,(1));
cljs.core.async.impl.dispatch.run.call(null,((function (c__13855__auto__,map__19941,map__19941__$1,repositories,coordinates,retrieve,local_repo,proxy,mirrors,managed_coordinates){
return (function (){
var f__13856__auto__ = (function (){var switch__13839__auto__ = ((function (c__13855__auto__,map__19941,map__19941__$1,repositories,coordinates,retrieve,local_repo,proxy,mirrors,managed_coordinates){
return (function (state_19968){
var state_val_19969 = (state_19968[(1)]);
if((state_val_19969 === (7))){
var inst_19955 = (state_19968[(2)]);
var inst_19956 = cljs.core.map.call(null,eginez.huckleberry.core.dependency,coordinates);
var inst_19957 = eginez.huckleberry.core.resolve_all.call(null,inst_19956,new cljs.core.Keyword(null,"repositories","repositories",1367837581),inst_19955,new cljs.core.Keyword(null,"local-repo","local-repo",764410280),local_repo);
var state_19968__$1 = state_19968;
return cljs.core.async.impl.ioc_helpers.take_BANG_.call(null,state_19968__$1,(8),inst_19957);
} else {
if((state_val_19969 === (1))){
var state_19968__$1 = state_19968;
if(cljs.core.truth_(local_repo)){
var statearr_19973_20034 = state_19968__$1;
(statearr_19973_20034[(1)] = (2));

} else {
var statearr_19974_20035 = state_19968__$1;
(statearr_19974_20035[(1)] = (3));

}

return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19969 === (4))){
var inst_19949 = (state_19968[(2)]);
var state_19968__$1 = (function (){var statearr_19976 = state_19968;
(statearr_19976[(7)] = inst_19949);

return statearr_19976;
})();
if(cljs.core.truth_(repositories)){
var statearr_19978_20036 = state_19968__$1;
(statearr_19978_20036[(1)] = (5));

} else {
var statearr_19979_20037 = state_19968__$1;
(statearr_19979_20037[(1)] = (6));

}

return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19969 === (6))){
var inst_19949 = (state_19968[(7)]);
var inst_19952 = cljs.core.assoc.call(null,eginez.huckleberry.core.default_repos,new cljs.core.Keyword(null,"local","local",-1497766724),inst_19949);
var inst_19953 = cljs.core.vals.call(null,inst_19952);
var state_19968__$1 = state_19968;
var statearr_19980_20041 = state_19968__$1;
(statearr_19980_20041[(2)] = inst_19953);

(statearr_19980_20041[(1)] = (7));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19969 === (3))){
var inst_19947 = new cljs.core.Keyword(null,"local","local",-1497766724).cljs$core$IFn$_invoke$arity$1(eginez.huckleberry.core.default_repos);
var state_19968__$1 = state_19968;
var statearr_19981_20044 = state_19968__$1;
(statearr_19981_20044[(2)] = inst_19947);

(statearr_19981_20044[(1)] = (4));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19969 === (12))){
var inst_19963 = (state_19968[(2)]);
var state_19968__$1 = state_19968;
var statearr_19983_20045 = state_19968__$1;
(statearr_19983_20045[(2)] = inst_19963);

(statearr_19983_20045[(1)] = (11));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19969 === (2))){
var state_19968__$1 = state_19968;
var statearr_19984_20047 = state_19968__$1;
(statearr_19984_20047[(2)] = local_repo);

(statearr_19984_20047[(1)] = (4));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19969 === (11))){
var inst_19966 = (state_19968[(2)]);
var state_19968__$1 = state_19968;
return cljs.core.async.impl.ioc_helpers.return_chan.call(null,state_19968__$1,inst_19966);
} else {
if((state_val_19969 === (9))){
var inst_19949 = (state_19968[(7)]);
var inst_19959 = (state_19968[(8)]);
var inst_19961 = eginez.huckleberry.core.retrieve_dependencies.call(null,inst_19959,inst_19949,false);
var state_19968__$1 = state_19968;
return cljs.core.async.impl.ioc_helpers.take_BANG_.call(null,state_19968__$1,(12),inst_19961);
} else {
if((state_val_19969 === (5))){
var state_19968__$1 = state_19968;
var statearr_19987_20050 = state_19968__$1;
(statearr_19987_20050[(2)] = repositories);

(statearr_19987_20050[(1)] = (7));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19969 === (10))){
var inst_19959 = (state_19968[(8)]);
var state_19968__$1 = state_19968;
var statearr_19988_20052 = state_19968__$1;
(statearr_19988_20052[(2)] = inst_19959);

(statearr_19988_20052[(1)] = (11));


return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
if((state_val_19969 === (8))){
var inst_19959 = (state_19968[(2)]);
var state_19968__$1 = (function (){var statearr_19998 = state_19968;
(statearr_19998[(8)] = inst_19959);

return statearr_19998;
})();
if(cljs.core.truth_(retrieve)){
var statearr_19999_20055 = state_19968__$1;
(statearr_19999_20055[(1)] = (9));

} else {
var statearr_20000_20056 = state_19968__$1;
(statearr_20000_20056[(1)] = (10));

}

return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
return null;
}
}
}
}
}
}
}
}
}
}
}
}
});})(c__13855__auto__,map__19941,map__19941__$1,repositories,coordinates,retrieve,local_repo,proxy,mirrors,managed_coordinates))
;
return ((function (switch__13839__auto__,c__13855__auto__,map__19941,map__19941__$1,repositories,coordinates,retrieve,local_repo,proxy,mirrors,managed_coordinates){
return (function() {
var eginez$huckleberry$core$state_machine__13840__auto__ = null;
var eginez$huckleberry$core$state_machine__13840__auto____0 = (function (){
var statearr_20004 = [null,null,null,null,null,null,null,null,null];
(statearr_20004[(0)] = eginez$huckleberry$core$state_machine__13840__auto__);

(statearr_20004[(1)] = (1));

return statearr_20004;
});
var eginez$huckleberry$core$state_machine__13840__auto____1 = (function (state_19968){
while(true){
var ret_value__13841__auto__ = (function (){try{while(true){
var result__13842__auto__ = switch__13839__auto__.call(null,state_19968);
if(cljs.core.keyword_identical_QMARK_.call(null,result__13842__auto__,new cljs.core.Keyword(null,"recur","recur",-437573268))){
continue;
} else {
return result__13842__auto__;
}
break;
}
}catch (e20007){if((e20007 instanceof Object)){
var ex__13843__auto__ = e20007;
var statearr_20008_20062 = state_19968;
(statearr_20008_20062[(5)] = ex__13843__auto__);


cljs.core.async.impl.ioc_helpers.process_exception.call(null,state_19968);

return new cljs.core.Keyword(null,"recur","recur",-437573268);
} else {
throw e20007;

}
}})();
if(cljs.core.keyword_identical_QMARK_.call(null,ret_value__13841__auto__,new cljs.core.Keyword(null,"recur","recur",-437573268))){
var G__20070 = state_19968;
state_19968 = G__20070;
continue;
} else {
return ret_value__13841__auto__;
}
break;
}
});
eginez$huckleberry$core$state_machine__13840__auto__ = function(state_19968){
switch(arguments.length){
case 0:
return eginez$huckleberry$core$state_machine__13840__auto____0.call(this);
case 1:
return eginez$huckleberry$core$state_machine__13840__auto____1.call(this,state_19968);
}
throw(new Error('Invalid arity: ' + arguments.length));
};
eginez$huckleberry$core$state_machine__13840__auto__.cljs$core$IFn$_invoke$arity$0 = eginez$huckleberry$core$state_machine__13840__auto____0;
eginez$huckleberry$core$state_machine__13840__auto__.cljs$core$IFn$_invoke$arity$1 = eginez$huckleberry$core$state_machine__13840__auto____1;
return eginez$huckleberry$core$state_machine__13840__auto__;
})()
;})(switch__13839__auto__,c__13855__auto__,map__19941,map__19941__$1,repositories,coordinates,retrieve,local_repo,proxy,mirrors,managed_coordinates))
})();
var state__13857__auto__ = (function (){var statearr_20009 = f__13856__auto__.call(null);
(statearr_20009[cljs.core.async.impl.ioc_helpers.USER_START_IDX] = c__13855__auto__);

return statearr_20009;
})();
return cljs.core.async.impl.ioc_helpers.run_state_machine_wrapped.call(null,state__13857__auto__);
});})(c__13855__auto__,map__19941,map__19941__$1,repositories,coordinates,retrieve,local_repo,proxy,mirrors,managed_coordinates))
);

return c__13855__auto__;
});

eginez.huckleberry.core.resolve_dependencies.cljs$lang$maxFixedArity = (0);

eginez.huckleberry.core.resolve_dependencies.cljs$lang$applyTo = (function (seq19937){
return eginez.huckleberry.core.resolve_dependencies.cljs$core$IFn$_invoke$arity$variadic(cljs.core.seq.call(null,seq19937));
});

