var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports.parseProvisioningProfiles=void 0;var _path=_interopRequireDefault(require("path"));
var _fs=_interopRequireDefault(require("fs"));
var _chalk=_interopRequireDefault(require("chalk"));
var _iosMobileprovisionFinder=require("ios-mobileprovision-finder");
var _common=require("../../common");


















var _projectParser=require("../../projectTools/projectParser");
var _constants=require("../../constants");
var _pluginTools=require("../../pluginTools");
var _index=require("./index");
var _fileutils=require("../../systemTools/fileutils");


var parseProvisioningProfiles=function parseProvisioningProfiles(c){return new Promise(function(resolve,reject){

var teamID=(0,_common.getConfigProp)(c,c.platform,'teamID');
var id=(0,_common.getConfigProp)(c,c.platform,'id');
var certificates=_iosMobileprovisionFinder.cert.read();
var provisionProfiles=_iosMobileprovisionFinder.provision.read();
var result=_iosMobileprovisionFinder.provision.select(provisionProfiles,{
AppId:id,
TeamIdentifier:teamID,
Certificates:certificates.valid});

resolve(result);
});};exports.parseProvisioningProfiles=parseProvisioningProfiles;
//# sourceMappingURL=provisionParser.js.map