Skip to content

Commit

Permalink
Merge branch 'release/3.7.0' into 'develop'
Browse files Browse the repository at this point in the history
Release/3.7.0

See merge request papers/airgap/airgap-vault!247
  • Loading branch information
godenzim committed Apr 23, 2021
2 parents 5157fc0 + b7e1f48 commit cfe3ba1
Show file tree
Hide file tree
Showing 14 changed files with 151 additions and 64 deletions.
28 changes: 18 additions & 10 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,14 @@ stages:
- qa
- native_build
- native_test
- publish

build_ionic:
stage: build
script:
- docker build -t $GOOGLE_TAG .
tags:
- android-ui
- docker

unit:
stage: test
Expand All @@ -32,7 +33,7 @@ unit:
- docker rm unit-$CI_COMMIT_SHA
- docker rm lint-$CI_COMMIT_SHA
tags:
- android-ui
- docker
artifacts:
paths:
- lcov.info
Expand All @@ -42,7 +43,7 @@ build_android:
stage: native_build
when: manual
tags:
- android-ui
- docker
variables:
LOCAL_ANDROID: 'android-$CI_PIPELINE_ID'
script:
Expand Down Expand Up @@ -97,14 +98,13 @@ qa:
after_script:
- docker rm -f qa-$CI_PIPELINE_ID || true
tags:
- android-ui
- docker

build_ios:
stage: native_build
when: manual
before_script:
- echo "$IOS_BUILD_JSON" > build.json
- echo "$IOS_EXPORT_OPTIONS" > exportOptions.plist
script:
- export DEVELOPER_DIR=$XCODE_PATH
- nvm use 14
Expand All @@ -115,13 +115,21 @@ build_ios:
- npx ionic info
- npx ionic build --prod
- npx cap sync ios
- xcodebuild -workspace ios/App/App.xcworkspace -scheme "App" -destination generic/platform=iOS -configuration Release archive -archivePath ios/App.xcarchive MARKETING_VERSION=$VERSION CURRENT_PROJECT_VERSION=$CI_PIPELINE_ID -allowProvisioningUpdates
- xcodebuild -exportArchive -archivePath ios/App.xcarchive -exportOptionsPlist exportOptions.plist -exportPath ios/ -allowProvisioningUpdates
- xcrun altool --upload-app -f ios/App.ipa -u $IOS_USERNAME -p $IOS_PASSWORD
- xcodebuild -workspace ios/App/App.xcworkspace -scheme "App" -destination generic/platform=iOS -configuration Release archive -archivePath ios/airgap-vault-$VERSION-$CI_PIPELINE_ID.xcarchive MARKETING_VERSION=$VERSION CURRENT_PROJECT_VERSION=$CI_PIPELINE_ID -allowProvisioningUpdates
artifacts:
paths:
- ios/App.ipa
- ios/App.xcarchive
- ios/airgap-vault-$VERSION-$CI_PIPELINE_ID.xcarchive
tags:
- ios

publish_ios:
stage: publish
when: manual
before_script:
- echo "$IOS_EXPORT_OPTIONS" > exportOptions.plist
script:
- export DEVELOPER_DIR=$XCODE_PATH
- xcodebuild -exportArchive -archivePath ios/airgap-vault-$VERSION-$CI_PIPELINE_ID.xcarchive -exportOptionsPlist exportOptions.plist -exportPath ios/ -allowProvisioningUpdates
- xcrun altool --upload-app -f ios/App.ipa -u $IOS_USERNAME -p $IOS_PASSWORD
tags:
- ios
2 changes: 1 addition & 1 deletion android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ dependencies {
implementation 'com.google.android.material:material:1.2.0'
implementation 'com.scottyab:rootbeer-lib:0.0.7'

def saplingVersion = "0.0.5-beta10"
def saplingVersion = "0.0.6"
implementation "com.github.airgap-it:airgap-sapling:$saplingVersion"
}

Expand Down
30 changes: 19 additions & 11 deletions ios/App/App.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
/* Begin PBXBuildFile section */
2FAD9763203C412B000D30F8 /* config.xml in Resources */ = {isa = PBXBuildFile; fileRef = 2FAD9762203C412B000D30F8 /* config.xml */; };
49690A7E25C2BF80004A3586 /* VaultError.swift in Sources */ = {isa = PBXBuildFile; fileRef = 49690A7D25C2BF80004A3586 /* VaultError.swift */; };
49D642732629D22A0066C013 /* SaplingFFI in Frameworks */ = {isa = PBXBuildFile; productRef = 49D642722629D22A0066C013 /* SaplingFFI */; };
49D642752629D22A0066C013 /* Sapling in Frameworks */ = {isa = PBXBuildFile; productRef = 49D642742629D22A0066C013 /* Sapling */; };
50379B232058CBB4000EE86E /* capacitor.config.json in Resources */ = {isa = PBXBuildFile; fileRef = 50379B222058CBB4000EE86E /* capacitor.config.json */; };
504EC3081FED79650016851F /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 504EC3071FED79650016851F /* AppDelegate.swift */; };
504EC30D1FED79650016851F /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 504EC30B1FED79650016851F /* Main.storyboard */; };
Expand All @@ -17,7 +19,6 @@
50B271D11FEDC1A000F3C39B /* public in Resources */ = {isa = PBXBuildFile; fileRef = 50B271D01FEDC1A000F3C39B /* public */; };
885F55E825EE224200D85A88 /* SaplingNative.m in Sources */ = {isa = PBXBuildFile; fileRef = 885F55E725EE224200D85A88 /* SaplingNative.m */; };
885F55EB25EE226300D85A88 /* SaplingNative.swift in Sources */ = {isa = PBXBuildFile; fileRef = 885F55EA25EE226300D85A88 /* SaplingNative.swift */; };
888EC6D125EFE88400F0947F /* Sapling in Frameworks */ = {isa = PBXBuildFile; productRef = 888EC6D025EFE88400F0947F /* Sapling */; };
88AE2EE823D5C7A500428560 /* SecurityUtils.swift in Sources */ = {isa = PBXBuildFile; fileRef = 88AE2EE723D5C7A500428560 /* SecurityUtils.swift */; };
88AE2EED23D5CB3200428560 /* PluginCall+Additions.swift in Sources */ = {isa = PBXBuildFile; fileRef = 88AE2EEC23D5CB3200428560 /* PluginCall+Additions.swift */; };
88AE2EEF23D5D7B300428560 /* SecurityUtils.m in Sources */ = {isa = PBXBuildFile; fileRef = 88AE2EEE23D5D7B300428560 /* SecurityUtils.m */; };
Expand Down Expand Up @@ -71,8 +72,9 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
49D642752629D22A0066C013 /* Sapling in Frameworks */,
A084ECDBA7D38E1E42DFC39D /* Pods_App.framework in Frameworks */,
888EC6D125EFE88400F0947F /* Sapling in Frameworks */,
49D642732629D22A0066C013 /* SaplingFFI in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down Expand Up @@ -213,7 +215,8 @@
);
name = App;
packageProductDependencies = (
888EC6D025EFE88400F0947F /* Sapling */,
49D642722629D22A0066C013 /* SaplingFFI */,
49D642742629D22A0066C013 /* Sapling */,
);
productName = App;
productReference = 504EC3041FED79650016851F /* App.app */;
Expand Down Expand Up @@ -245,7 +248,7 @@
);
mainGroup = 504EC2FB1FED79650016851F;
packageReferences = (
888EC6CF25EFE88400F0947F /* XCRemoteSwiftPackageReference "airgap-sapling" */,
49D642712629D22A0066C013 /* XCRemoteSwiftPackageReference "airgap-sapling" */,
);
productRefGroup = 504EC3051FED79650016851F /* Products */;
projectDirPath = "";
Expand Down Expand Up @@ -296,10 +299,10 @@
buildActionMask = 2147483647;
files = (
);
inputFileListPaths = (
inputPaths = (
);
name = "[CP] Embed Pods Frameworks";
outputFileListPaths = (
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
Expand Down Expand Up @@ -543,20 +546,25 @@
/* End XCConfigurationList section */

/* Begin XCRemoteSwiftPackageReference section */
888EC6CF25EFE88400F0947F /* XCRemoteSwiftPackageReference "airgap-sapling" */ = {
49D642712629D22A0066C013 /* XCRemoteSwiftPackageReference "airgap-sapling" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "https://github.com/airgap-it/airgap-sapling";
requirement = {
kind = exactVersion;
version = "0.0.5-beta10";
kind = upToNextMajorVersion;
minimumVersion = 0.0.6;
};
};
/* End XCRemoteSwiftPackageReference section */

/* Begin XCSwiftPackageProductDependency section */
888EC6D025EFE88400F0947F /* Sapling */ = {
49D642722629D22A0066C013 /* SaplingFFI */ = {
isa = XCSwiftPackageProductDependency;
package = 49D642712629D22A0066C013 /* XCRemoteSwiftPackageReference "airgap-sapling" */;
productName = SaplingFFI;
};
49D642742629D22A0066C013 /* Sapling */ = {
isa = XCSwiftPackageProductDependency;
package = 888EC6CF25EFE88400F0947F /* XCRemoteSwiftPackageReference "airgap-sapling" */;
package = 49D642712629D22A0066C013 /* XCRemoteSwiftPackageReference "airgap-sapling" */;
productName = Sapling;
};
/* End XCSwiftPackageProductDependency section */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
"repositoryURL": "https://github.com/airgap-it/airgap-sapling",
"state": {
"branch": null,
"revision": "aa23b91ba46c93723eca27fa1b41ea4064b9ef1c",
"version": "0.0.5-beta10"
"revision": "c6606fce5d84cea678414681b13ef5efb3629a7e",
"version": "0.0.6"
}
}
]
Expand Down
20 changes: 19 additions & 1 deletion ios/App/App.xcodeproj/xcshareddata/xcschemes/App.xcscheme
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1140"
version = "1.3">
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
Expand Down Expand Up @@ -74,5 +74,23 @@
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
<PostActions>
<ExecutionAction
ActionType = "Xcode.IDEStandardExecutionActionsCore.ExecutionActionType.ShellScriptAction">
<ActionContent
title = "Run Script"
scriptText = "for STATIC_LIB in &quot;${ARCHIVE_PATH}&quot;/Products/Applications/&quot;${PRODUCT_NAME}&quot;.app/frameworks/*.a&#10;do&#10; echo &quot;Removing &apos;${STATIC_LIB}&apos;&quot;&#10; rm -r &quot;${STATIC_LIB}&quot;&#10;done&#10;">
<EnvironmentBuildable>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "504EC3031FED79650016851F"
BuildableName = "App.app"
BlueprintName = "App"
ReferencedContainer = "container:App.xcodeproj">
</BuildableReference>
</EnvironmentBuildable>
</ActionContent>
</ExecutionAction>
</PostActions>
</ArchiveAction>
</Scheme>
4 changes: 2 additions & 2 deletions ios/App/App.xcworkspace/xcshareddata/swiftpm/Package.resolved
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
"repositoryURL": "https://github.com/airgap-it/airgap-sapling",
"state": {
"branch": null,
"revision": "aa23b91ba46c93723eca27fa1b41ea4064b9ef1c",
"version": "0.0.5-beta10"
"revision": "c6606fce5d84cea678414681b13ef5efb3629a7e",
"version": "0.0.6"
}
}
]
Expand Down
57 changes: 36 additions & 21 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@
"apply-diagnostic-modules": "node apply-diagnostic-modules.js"
},
"dependencies": {
"@airgap/angular-core": "0.0.9-beta.13",
"@airgap/angular-ngrx": "0.0.9-beta.13",
"@airgap/coinlib-core": "0.10.7-beta.3",
"@airgap/sapling-wasm": "0.0.5-beta.10",
"@airgap/angular-core": "0.0.9",
"@airgap/angular-ngrx": "0.0.9",
"@airgap/coinlib-core": "0.11.0",
"@airgap/sapling-wasm": "0.0.6",
"@angular/common": "^11.0.4",
"@angular/core": "^11.0.4",
"@angular/forms": "^11.0.4",
Expand Down
5 changes: 5 additions & 0 deletions src/app/app.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,11 @@ export class AppComponent implements AfterViewInit {
}

private async getSaplingParams(type: 'spend' | 'output'): Promise<Buffer> {
if (this.platform.is('hybrid')) {
// Sapling params are read and used in a native plugin, there's no need to read them in the Ionic part
return Buffer.alloc(0)
}

const params: ArrayBuffer = await this.httpClient
.get(`./assets/sapling/sapling-${type}.params`, { responseType: 'arraybuffer' })
.toPromise()
Expand Down
Loading

0 comments on commit cfe3ba1

Please sign in to comment.