Skip to content

Commit

Permalink
Merge pull request #817 from tchapgouv/816-deploy-new-cryptosdk-rust-…
Browse files Browse the repository at this point in the history
…partially-to-prod-and-fully-to-preprod-and-dev

Deploy new CryptoSDK (Rust) partially to PROD and fully to Preprod an…
  • Loading branch information
NicolasBuquet authored Apr 26, 2023
2 parents 91a6dd1 + 09378e7 commit aa29e9e
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 6 deletions.
15 changes: 11 additions & 4 deletions Riot/Experiments/CryptoSDKFeature.swift
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,17 @@ import MatrixSDKCrypto
localTargetPercentage: Double = 1
) {
self.remoteFeature = remoteFeature
self.localFeature = PhasedRolloutFeature(
name: Self.FeatureName,
targetPercentage: localTargetPercentage
)
// Tchap
// self.localFeature = PhasedRolloutFeature(name: Self.FeatureName, targetPercentage: localTargetPercentage)
#if TCHAP_PRODUCTION
self.localFeature = PhasedRolloutFeature(name: Self.FeatureName, targetPercentage: 0.25)
#elseif TCHAP_PREPRODUCTION
self.localFeature = PhasedRolloutFeature(name: Self.FeatureName, targetPercentage: 1.0)
#elseif TCHAP_DEVELOPMENT
self.localFeature = PhasedRolloutFeature(name: Self.FeatureName, targetPercentage: 1.0)
#else
self.localFeature = PhasedRolloutFeature(name: Self.FeatureName, targetPercentage: localTargetPercentage)
#endif
}

func enable() {
Expand Down
14 changes: 12 additions & 2 deletions Tchap/target.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,6 @@ targetTemplates:

settings:
INFOPLIST_FILE: "${target_name}/SupportingFiles/Info.plist"
GCC_PREPROCESSOR_DEFINITIONS: $(inherited) SECURE_BACKUP=1 CROSS_SIGNING=1
OTHER_SWIFT_FLAGS: $(inherited) -D SECURE_BACKUP -D CROSS_SIGNING

sources:
- path: ../Config/AppConfiguration.swift
Expand Down Expand Up @@ -335,6 +333,10 @@ targets:
Debug: ../Tchap/SupportingFiles/App-Debug.xcconfig
Release: ../Tchap/SupportingFiles/App-Release.xcconfig

settings:
GCC_PREPROCESSOR_DEFINITIONS: $(inherited) SECURE_BACKUP=1 CROSS_SIGNING=1 TCHAP_PRODUCTION=1
OTHER_SWIFT_FLAGS: $(inherited) -D SECURE_BACKUP -D CROSS_SIGNING -D TCHAP_PRODUCTION

sources:
- path: ../Tchap/Assets
excludes:
Expand All @@ -350,6 +352,10 @@ targets:
Debug: ../Btchap/SupportingFiles/Btchap-App-Debug.xcconfig
Release: ../Btchap/SupportingFiles/Btchap-App-Release.xcconfig

settings:
GCC_PREPROCESSOR_DEFINITIONS: $(inherited) SECURE_BACKUP=1 CROSS_SIGNING=1 TCHAP_PREPRODUCTION=1
OTHER_SWIFT_FLAGS: $(inherited) -D SECURE_BACKUP -D CROSS_SIGNING -D TCHAP_PREPRODUCTION

sources:
- path: ../Btchap
excludes:
Expand All @@ -364,6 +370,10 @@ targets:
Debug: ../DevTchap/SupportingFiles/DevTchap-App-Debug.xcconfig
Release: ../DevTchap/SupportingFiles/DevTchap-App-Release.xcconfig

settings:
GCC_PREPROCESSOR_DEFINITIONS: $(inherited) SECURE_BACKUP=1 CROSS_SIGNING=1 TCHAP_DEVELOPMENT=1
OTHER_SWIFT_FLAGS: $(inherited) -D SECURE_BACKUP -D CROSS_SIGNING -D TCHAP_DEVELOPMENT

sources:
- path: ../DevTchap
excludes:
Expand Down
1 change: 1 addition & 0 deletions changelog.d/816.change
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Deploy new CryptoSDK (Rust) partially to PROD and fully to Preprod and Dev (#816)

0 comments on commit aa29e9e

Please sign in to comment.