Skip to content

Commit 1aed698

Browse files
authored
release/0.2.0 (#14)
1 parent 35a2a9e commit 1aed698

File tree

7 files changed

+33
-8
lines changed

7 files changed

+33
-8
lines changed

CHANGELOG.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
# 0.2.0
2+
Version update and bug fixes.
3+
4+
## 🎯 Improvements
5+
- Added compatibility for freeRASP 4.0.0
6+
7+
## 🛠 Fixed issues
8+
- Post-script failed when scheme update were set to false
9+
110
# 0.1.0
211
**🎉 First release on BrickHub.dev! 🎉**
312

__brick__/lib/freerasp/freerasp.g.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ TalsecConfig _config = TalsecConfig(
99
watcherMail: '{{watcher_mail}}',{{#android}}
1010
androidConfig: AndroidConfig(
1111
expectedPackageName: '{{package_name}}',
12-
expectedSigningCertificateHash: '{{signing_hash}}',
12+
expectedSigningCertificateHashes: {{{signing_hashes}}},
1313
),{{/android}}{{#ios}}
1414
iosConfig: IOSconfig(
1515
appBundleId: '{{bundle_id}}',

brick.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name: freerasp_brick
22
description: A brick for configuration generation and automatic setup for freeRASP.
3-
4-
version: 0.1.0
3+
repository: https://github.com/yardexx/freerasp_brick
4+
version: 0.2.0
55

66
environment:
77
mason: ">=0.1.0-dev.39 <0.1.0"

hooks/analysis_options.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
include: package:very_good_analysis/analysis_options.3.0.1.yaml
1+
include: package:very_good_analysis/analysis_options.3.1.0.yaml

hooks/extensions.dart

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,13 @@ extension LoggerX on Logger {
2424
);
2525
}
2626
}
27+
28+
extension StringX on String {
29+
String toListString() {
30+
return split(',')
31+
.map((item) => item.trim())
32+
.map((item) => "'$item'")
33+
.toList()
34+
.toString();
35+
}
36+
}

hooks/post_gen.dart

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,16 @@ const String flutterBuild = 'lib';
1010

1111
Future<void> run(HookContext context) async {
1212
final logger = context.logger;
13+
14+
final isAndroid = context.vars['android'] as bool;
15+
final isIOS = context.vars['ios'] as bool;
16+
1317
await _runPubAdd(logger);
1418
await _runPubGet(logger);
1519
await _runDartFix(logger);
16-
await _runGradleCheck(context);
17-
await _runSchemeCheck(context);
20+
21+
if (isAndroid) await _runGradleCheck(context);
22+
if (isIOS) await _runSchemeCheck(context);
1823
}
1924

2025
Future<void> _runPubAdd(Logger logger) async {

hooks/pre_gen.dart

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,8 @@ void parseAndroidData(HookContext context) {
4747
defaultValue: defaultAppPackage,
4848
);
4949

50-
final signingHash = logger.masonPrompt("What's app singing hash?");
50+
final signingHashes =
51+
logger.masonPrompt('What are app singing hashes?').toListString();
5152

5253
final updateGradle = logger.masonConfirm(
5354
'Do you want to check and update API level (minSdkVersion)?',
@@ -56,7 +57,7 @@ void parseAndroidData(HookContext context) {
5657

5758
context.vars.addAll({
5859
'package_name': packageName,
59-
'signing_hash': signingHash,
60+
'signing_hashes': signingHashes,
6061
'update_gradle': updateGradle,
6162
});
6263
}

0 commit comments

Comments
 (0)