From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by mx.groups.io with SMTP id smtpd.web10.8245.1589072681934041017 for ; Sat, 09 May 2020 18:04:42 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@intel.onmicrosoft.com header.s=selector2-intel-onmicrosoft-com header.b=YRl72y46; spf=pass (domain: intel.com, ip: 134.134.136.31, mailfrom: nathaniel.l.desimone@intel.com) IronPort-SDR: aEpH3J2FejKN+AIkoMKYlU6wTuV/pKZZ72iWgOvQ2hec/sXxtwJTAc9o5t+c3sRRLE3Ld2rdZS oVaeXnxYrGZA== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 May 2020 18:04:41 -0700 IronPort-SDR: bTUGBEv0S0nCxXeeP9bSXCQ0RflGBxymaAoJURQx9dHwtt2F9o3FD7P4nIr4MsDw6CvaZmts79 IeJAgMeg98ZA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.73,373,1583222400"; d="scan'208";a="305841912" Received: from orsmsx107.amr.corp.intel.com ([10.22.240.5]) by FMSMGA003.fm.intel.com with ESMTP; 09 May 2020 18:04:40 -0700 Received: from orsmsx609.amr.corp.intel.com (10.22.229.22) by ORSMSX107.amr.corp.intel.com (10.22.240.5) with Microsoft SMTP Server (TLS) id 14.3.439.0; Sat, 9 May 2020 18:04:40 -0700 Received: from orsmsx609.amr.corp.intel.com (10.22.229.22) by ORSMSX609.amr.corp.intel.com (10.22.229.22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5; Sat, 9 May 2020 18:04:40 -0700 Received: from ORSEDG002.ED.cps.intel.com (10.7.248.5) by orsmsx609.amr.corp.intel.com (10.22.229.22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.1.1713.5 via Frontend Transport; Sat, 9 May 2020 18:04:40 -0700 Received: from NAM10-DM6-obe.outbound.protection.outlook.com (104.47.58.103) by edgegateway.intel.com (134.134.137.101) with Microsoft SMTP Server (TLS) id 14.3.439.0; Sat, 9 May 2020 18:04:39 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=AwoKVxT0TPIMtTMqbH6I7nAiXD+PpyQRTA5eo9iTU53UEwbu8G5QWoah8Ga30kQKGkKKkPkXah/PLXMqMpZdUzixrkHlOLo+beC9Rqm5NPRRrdS/c2JQdA4fKfO20MWL71BC8VwclrIZAVpcJ0shpBVXJ/gnsgi8Rs1468ICxxPrZe16PVCGnVfe7K8xcGZED1y3o9JXKQba1DulLSV4IaUpMvluAB1AOlQgZkuQ138MVWZ3i9T19q2OsSfExCyvD6+DJUKqV0ictJPjCiD8w2q99pdswLltyVK0aCEUcESFLP2X3Zfr8ZYxi5VDObLHKxVJySgM/j7IAi2mQGH/SQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=A4Jnc2naSoUjzqNxs7MmBR2cwlRuWD8sShuEYGiSysE=; b=bv7AO0VusCNrfp+uJBkVJp6dZ4seQxrDabwLuevQ6k0ELe0AQXneJFskR4vYWIpCUL4/cqJha365t65FMsG6QnRCyFb370cX3WZXjlN1a5dRt0Wv3SPGDWaCXpNc3JyhYHF62LDKG3ChNbGj0ZTkYwL3X9HPTkRzbkk1y/X0ebTRLlby9eXOf0Pmq1dhH3tUo2MO+74flsl1fpITPN54KT7LOvcfD7BsRiljGNh70V1tOYmtn2rX4ExN75gYdNjsi4YxKKWX5un+dSq0Heu/ho/RKoy3q0Nx0Ss220Q4mxq6mK7NbLjo4nuvqs1332m7+xa+SmfjSLW9N+DBo0X/Hw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=A4Jnc2naSoUjzqNxs7MmBR2cwlRuWD8sShuEYGiSysE=; b=YRl72y46Yrh/al8rh//B2+y6BPdnw69h+uhyEV2A3hgW3/ucjw9OeNwkGwtQ4iw4kU4g8cSgEyRpYOwf8knp1sD7CA9CHECaqbUTCd7Vd+3DjPD7zGAJPSc52kHwX6OjLuEpFgfPIW8fmmsf67IsqYt6Y45ULPcNpJKB8PGcqak= Received: from BL0PR11MB3489.namprd11.prod.outlook.com (2603:10b6:208:75::29) by BL0PR11MB3443.namprd11.prod.outlook.com (2603:10b6:208:6c::26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2979.33; Sun, 10 May 2020 01:04:38 +0000 Received: from BL0PR11MB3489.namprd11.prod.outlook.com ([fe80::d0f8:bfd7:bae2:3e42]) by BL0PR11MB3489.namprd11.prod.outlook.com ([fe80::d0f8:bfd7:bae2:3e42%7]) with mapi id 15.20.2979.033; Sun, 10 May 2020 01:04:38 +0000 From: "Nate DeSimone" To: "Desimone, Ashley E" , "devel@edk2.groups.io" CC: "Pandya, Puja" , "Bjorge, Erik C" , Bret Barkelew , "Agyeman, Prince" Subject: Re: [edk2-staging/EdkRepo] [PATCH V2] EkdRepo: Update Checkout Pin to Support Multiple Manifest Repos Thread-Topic: [edk2-staging/EdkRepo] [PATCH V2] EkdRepo: Update Checkout Pin to Support Multiple Manifest Repos Thread-Index: AQHWJW0PNrIffL7ojkqf0mY/K4mfWqiggv5A Date: Sun, 10 May 2020 01:04:38 +0000 Message-ID: References: <20200508191456.10508-1-ashley.e.desimone@intel.com> In-Reply-To: <20200508191456.10508-1-ashley.e.desimone@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiYmM3NTZhMjgtNDQ1NS00ZTM3LTk2NmEtMTk1OTg4ZGRlYjBhIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoib0JGYmcwam1wTkxnWURIRmVMUHhwanhlOThUaWxVcGJ5VDN6a1EzeUlOWHVoS1RYY0k4cUpjbTVjNHhVXC9JQjkifQ== dlp-reaction: no-action dlp-version: 11.2.0.6 dlp-product: dlpe-windows x-ctpclassification: CTP_NT authentication-results: intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=none action=none header.from=intel.com; x-originating-ip: [50.53.190.176] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: b38c677b-763c-46d4-a007-08d7f47e1cfe x-ms-traffictypediagnostic: BL0PR11MB3443: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:3383; x-forefront-prvs: 039975700A x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: wMYEOAxwrKBriTUcZgFIFCz+MvyYwhCV2NwIsTpaK3vOssaorDZZ7/VUrNBCdAsNJ45NRx2ypDJoPIl7axUajOUe1prFYEya77nwl8bKQQiyT/Ljs40J04965ctVcUCKQj1XjU9d6JDQMIrTPs6aDkda3keAJ9MqR/IiHUc0L4XtYDHENsJ7+tXgnxTtm10T70Rwx/zwSzOCPadrkiGMFNvBDzyxi5GCti+XcJYYJsUhddX0WhsvcFzC3Ht5iUc0pxWlbD9CicHXq8+1Cm/glniMVXSeJQmbHxSP5NTPbBVDz4LgEClvoclHH9XIAZ+B51qJSB9UrcKlb7yu5LPZTTFCMjoYALczNIiJFdkQlzEy/MWR4Xrk1i6aOIySNww+YSPTrZqU3F94miYgIfjW7DlhWi6o7n3W9e0elOAKWQK7hdaQ2rmAyNmkiD7j7+RM1SWpFzQp0obEd3jMCzQJikFNiL+kC1wG+hah8dslIDynBieZfUoduZ4pK70xlf6A5Lk9W7T2d9QtR7xCo9GRrQ== x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:BL0PR11MB3489.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(376002)(39860400002)(346002)(396003)(136003)(366004)(33430700001)(54906003)(52536014)(71200400001)(86362001)(26005)(15650500001)(186003)(5660300002)(6506007)(316002)(33656002)(2906002)(66446008)(64756008)(33440700001)(66476007)(76116006)(66946007)(66556008)(53546011)(478600001)(7696005)(110136005)(107886003)(4326008)(9686003)(8936002)(55016002)(8676002);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata: jdFsOkelTpcb6gHnTkvQwR+AyKIzqDCht19FcLEbHFwCDiZETrCrfI0jrv2Sdi6R7tSolFlAxmfh2ASlWFPsJAYZXEU9nmmkKRM9gDXLOwiGv70F8a0Yo2V5XN/KC5IXoS/AMVgTiqsaDbuoCCjmXsuXReUhiMZKedUZKlv/1Y9CFOypyMYIN3GGCT90WpP6LAbc9RuNgJqkZ4506Dq2CbB5jqPqMvl9oBmOEQtc9mpY3MBkH85qkbuI/cTZ76i4xYkCdPnUj43+KU2TL+O414LcKTcNPlthndUQCdFzTm/+YWLULkP3FCEm0k5/SbvchQY/1quQDSRmWXHpN2B1/pFmLEmsr2NEN67vikb6zACEY1P4V1oyZyConvZCK+swa6vCNVjotJ77njAONSJF+QFb3YWUAj9tqqTCHuFRvzdG366Iw30cv3x+TeFQ04g3HDOEK/jx6d2Lxqpxl3+Xr8070lIfs1EMd48hhoipEfc= MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: b38c677b-763c-46d4-a007-08d7f47e1cfe X-MS-Exchange-CrossTenant-originalarrivaltime: 10 May 2020 01:04:38.4061 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: yPPKTfFbsZE4IguXzTIkYjp5NFklb3w1FykWmEfKwoiByfpHtzve/+cyyejK/4n74AGTcvrMiEfm7woGrgCnuxResKPuuR0zeG9xt5jYhgk= X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL0PR11MB3443 Return-Path: nathaniel.l.desimone@intel.com X-OriginatorOrg: intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Nate DeSimone -----Original Message----- From: Desimone, Ashley E =20 Sent: Friday, May 8, 2020 12:15 PM To: devel@edk2.groups.io Cc: Desimone, Nathaniel L ; Pandya, Puja ; Bjorge, Erik C ; Bret Barke= lew ; Agyeman, Prince Subject: [edk2-staging/EdkRepo] [PATCH V2] EkdRepo: Update Checkout Pin to = Support Multiple Manifest Repos Update the checkout pin command to look for pin files only in the workspace= 's source manifest repository. Signed-off-by: Ashley E Desimone Cc: Nate DeSimone Cc: Puja Pandya Cc: Erik Bjorge Cc: Bret Barkelew Cc: Prince Agyeman --- edkrepo/commands/checkout_pin_command.py | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/edkrepo/commands/checkout_pin_command.py b/edkrepo/commands/ch= eckout_pin_command.py index 31df825..4aaf2b5 100644 --- a/edkrepo/commands/checkout_pin_command.py +++ b/edkrepo/commands/checkout_pin_command.py @@ -11,13 +11,15 @@ import os =20 from git import Repo =20 -from edkrepo.commands.edkrepo_command import EdkrepoCommand, OverrideArgum= ent +from edkrepo.commands.edkrepo_command import EdkrepoCommand,=20 +OverrideArgument, SourceManifestRepoArgument import edkrepo.commands.arguments.checkout_pin_args as arguments import e= dkrepo.commands.humble.checkout_pin_humble as humble from edkrepo.common.c= ommon_repo_functions import sparse_checkout_enabled, reset_sparse_checkout,= sparse_checkout from edkrepo.common.common_repo_functions import check_di= rty_repos, checkout_repos, combinations_in_manifest from edkrepo.common.hu= mble import SPARSE_CHECKOUT, SPARSE_RESET from edkrepo.common.edkrepo_exce= ption import EdkrepoInvalidParametersException, EdkrepoProjectMismatchExcep= tion +from edkrepo.common.workspace_maintenance.manifest_repos_maintenance=20 +import list_available_manifest_repos from=20 +edkrepo.common.workspace_maintenance.manifest_repos_maintenance import=20 +find_source_manifest_repo from edkrepo.config.config_factory import get_workspace_path, get_workspac= e_manifest from edkrepo_manifest_parser.edk_manifest import ManifestXml =20 @@ -38,12 +40,21 @@ class CheckoutPinCommand(EdkrepoCommand): 'required' : True, 'help-text' : arguments.PIN_FILE_HELP}) args.append(OverrideArgument) + args.append(SourceManifestRepoArgument) return metadata =20 def run_command(self, args, config): workspace_path =3D get_workspace_path() manifest =3D get_workspace_manifest() - pin_path =3D self.__get_pin_path(args, workspace_path, config['cfg= _file'].manifest_repo_abs_local_path, manifest) + + manifest_repo =3D find_source_manifest_repo(manifest, config['cfg_= file'], config['user_cfg_file'], args.source_manifest_repo) + cfg, user_cfg, conflicts =3D list_available_manifest_repos(config[= 'cfg_file'], config['user_cfg_file']) + if manifest_repo in cfg: + manifest_repo_path =3D config['cfg_file'].manifest_repo_abs_pa= th(manifest_repo) + elif manifest_repo in user_cfg: + manifest_repo_path =3D=20 + config['user_cfg_file'].manifest_repo_abs_path(manifest_repo) + + pin_path =3D self.__get_pin_path(args, workspace_path,=20 + manifest_repo_path, manifest) pin =3D ManifestXml(pin_path) manifest_sources =3D manifest.get_repo_sources(manifest.general_co= nfig.current_combo) check_dirty_repos(manifest, workspace_path) -- 2.16.2.windows.1