1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-01-20 00:08:02 +01:00

chore: add detect segment usage in CRs flag (#5302)

As the title says, this PR adds a flag to unleash for detecting segment
usage in CRs.
This commit is contained in:
Thomas Heartman 2023-11-08 15:06:01 +01:00 committed by GitHub
parent a5288ae0b1
commit ebf3102244
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 1 deletions

View File

@ -77,6 +77,7 @@ exports[`should create default config 1`] = `
"customRootRolesKillSwitch": false,
"demo": false,
"dependentFeatures": false,
"detectSegmentUsageInChangeRequests": false,
"disableBulkToggle": false,
"disableEnvsOnRevive": false,
"disableMetrics": false,

View File

@ -36,7 +36,8 @@ export type IFlagKey =
| 'featureSwitchRefactor'
| 'featureSearchAPI'
| 'featureSearchFrontend'
| 'scheduledConfigurationChanges';
| 'scheduledConfigurationChanges'
| 'detectSegmentUsageInChangeRequests';
export type IFlags = Partial<{ [key in IFlagKey]: boolean | Variant }>;
@ -172,6 +173,11 @@ const flags: IFlags = {
process.env.UNLEASH_EXPERIMENTAL_SCHEDULED_CONFIGURATION_CHANGES,
false,
),
detectSegmentUsageInChangeRequests: parseEnvVarBoolean(
process.env
.UNLEASH_EXPERIMENTAL_DETECT_SEGMENT_USAGE_IN_CHANGE_REQUESTS,
false,
),
};
export const defaultExperimentalOptions: IExperimentalOptions = {