Skip to content
This repository has been archived by the owner on Mar 18, 2024. It is now read-only.

Filter packages that are to be ignored from prepare #597

Merged
merged 1 commit into from
Jul 13, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 16 additions & 3 deletions packages/sfpowerscripts-cli/src/impl/prepare/PreparePool.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,22 @@ export default class PreparePool implements PreparePoolInterface {


private async getPackageArtifacts() {
let packages = ProjectConfig.getSFDXPackageManifest(null)[


//Filter Packages to be ignore from prepare to be fetched
let packages =ProjectConfig.getSFDXPackageManifest(null)[
"packageDirectories"
];
].filter((pkg)=>{
if (
pkg.ignoreOnStage?.find( (stage) => {
stage = stage.toLowerCase();
return stage === "prepare";
})
)
return false;
else
return true;
});


let artifactFetcher:FetchAnArtifact;
Expand All @@ -77,7 +90,7 @@ export default class PreparePool implements PreparePoolInterface {
).getArtifactFetcher();


packages.forEach((pkg) => {
packages.forEach((pkg) => {
artifactFetcher.fetchArtifact(
pkg.package,
"artifacts",
Expand Down