@salesforce/packaging 1.4.12 → 1.4.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -330,17 +330,16 @@ class PackageVersionCreate {
|
|
|
330
330
|
if (this.options.codecoverage) {
|
|
331
331
|
hasUnpackagedMetadata = await this.metadataResolver.resolveMetadata(unpackagedMetadataPath, unpackagedMetadataFolder, 'unpackagedMDDirectoryDoesNotExist', sourceApiVersion);
|
|
332
332
|
}
|
|
333
|
-
//
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
}
|
|
333
|
+
// don't package the profiles from any unpackagedMetadata dir in the project
|
|
334
|
+
const profileExcludeDirs = this.project
|
|
335
|
+
.getPackageDirectories()
|
|
336
|
+
.filter((packageDir) => packageDir.unpackagedMetadata?.path)
|
|
337
|
+
.map((packageDir) => packageDir.unpackagedMetadata.path);
|
|
338
|
+
typesArr = this.options.profileApi.filterAndGenerateProfilesForManifest(typesArr, profileExcludeDirs);
|
|
340
339
|
// Next generate profiles and retrieve any profiles that were excluded because they had no matching nodes.
|
|
341
340
|
const excludedProfiles = this.options.profileApi.generateProfiles(packageVersProfileFolder, {
|
|
342
341
|
Package: typesArr,
|
|
343
|
-
},
|
|
342
|
+
}, profileExcludeDirs);
|
|
344
343
|
if (excludedProfiles.length > 0) {
|
|
345
344
|
const profileIdx = typesArr.findIndex((e) => e.name[0] === 'Profile');
|
|
346
345
|
typesArr[profileIdx].members = typesArr[profileIdx].members.filter((e) => !excludedProfiles.includes(e));
|