From 4e81088ce4351945d62ed6cc2085bb9ec0dea260 Mon Sep 17 00:00:00 2001 From: sfopsbot Date: Tue, 19 Dec 2023 13:24:17 +1100 Subject: [PATCH] fix(validate): fix incorrect syntax and version --- packages/sfp-cli/package.json | 5 +- .../sfp-cli/src/impl/validate/ValidateImpl.ts | 46 +++++++++---------- 2 files changed, 24 insertions(+), 27 deletions(-) diff --git a/packages/sfp-cli/package.json b/packages/sfp-cli/package.json index 3315cffea..94f768333 100644 --- a/packages/sfp-cli/package.json +++ b/packages/sfp-cli/package.json @@ -1,12 +1,13 @@ { "name": "@flxblio/sfp", "description": "Flxbl Toolkit", - "version": "30.0.0", + "version": "30.0.2", "license": "MIT", "author": "flxblio", "release": "January 24", "bin": { - "sfp": "./bin/run" + "sfp": "./bin/run", + "sfpowerscripts": "./bin/run" }, "bugs": "https://github.com/flxbl-io/sfp/issues", "publishConfig": { diff --git a/packages/sfp-cli/src/impl/validate/ValidateImpl.ts b/packages/sfp-cli/src/impl/validate/ValidateImpl.ts index 5431d37ba..39e17c6ba 100644 --- a/packages/sfp-cli/src/impl/validate/ValidateImpl.ts +++ b/packages/sfp-cli/src/impl/validate/ValidateImpl.ts @@ -477,31 +477,27 @@ export default class ValidateImpl implements PostDeployHook, PreDeployHook { function computePackageOverrides(props: ValidateProps): { [key: string]: PackageType } { - let overridedPackages: { [key: string]: PackageType } = {}; - const allPackages = ProjectConfig.getAllPackages(null); - const projectConfig = ProjectConfig.getSFDXProjectConfig(null); - for (const pkg of allPackages) { - - if (ProjectConfig.getPackageType(projectConfig, pkg) !== PackageType.Data) { - if ( - props.validationMode === - ValidationMode.FASTFEEDBACK_LIMITED_BY_RELEASE_CONFIG || - props.validationMode === - ValidationMode.FAST_FEEDBACK - ) { - overridedPackages[pkg] = PackageType.Diff - } - else { - if (!props.disableSourcePackageOverride) { - if(ProjectConfig.getPackageType(projectConfig, pkg) == PackageType.Unlocked) - { - overridedPackages[pkg] = PackageType.Source - } - } - } - } - return overridedPackages; - } + let overridedPackages: { [key: string]: PackageType } = {}; + const allPackages = ProjectConfig.getAllPackages(null); + const projectConfig = ProjectConfig.getSFDXProjectConfig(null); + for (const pkg of allPackages) { + if (ProjectConfig.getPackageType(projectConfig, pkg) !== PackageType.Data) { + if ( + props.validationMode === ValidationMode.FASTFEEDBACK_LIMITED_BY_RELEASE_CONFIG || + props.validationMode === ValidationMode.FAST_FEEDBACK + ) { + overridedPackages[pkg] = PackageType.Diff; + } else { + if (!props.disableSourcePackageOverride) { + if (ProjectConfig.getPackageType(projectConfig, pkg) == PackageType.Unlocked) { + overridedPackages[pkg] = PackageType.Source; + } + } + } + } + } + return overridedPackages; + } function fetchPackagesAsPerReleaseConfig( logger: Logger,