Skip to content

Commit 0cb540a

Browse files
committed
Use ext instead of command line parameters
1 parent 03ca6d9 commit 0cb540a

File tree

3 files changed

+11
-9
lines changed

3 files changed

+11
-9
lines changed

appium/fastlane/Fastfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ platform :ios do
6868
end
6969

7070
lane :build_android_for_device_farm do
71-
android_build_output = sh("cd ../example/android/; ./gradlew -Psentryloglevel=debug assembleRelease --stacktrace")
71+
android_build_output = sh("cd ../example/android/; ./gradlew assembleRelease --stacktrace")
7272
validate_android_build_output(android_build_output)
7373
sh("jarsigner -verbose -digestalg SHA1 -sigalg MD5withRSA -keystore release.keystore -storepass 123456 ../example/android/app/build/outputs/apk/app-full-release-unsigned.apk release")
7474
end

examples

sentry.gradle

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
import org.apache.tools.ant.taskdefs.condition.Os
22

3+
def config = project.hasProperty("sentry") ? project.sentry : [];
4+
35
gradle.projectsEvaluated {
46
def releases = [];
57
android.applicationVariants.each { variant ->
@@ -44,7 +46,7 @@ gradle.projectsEvaluated {
4446
bundleTask.setProperty("commandLine", cmd);
4547
bundleTask.setProperty("args", cmdArgs);
4648

47-
if (project.hasProperty("flavoraware")) {
49+
if (config.flavorAware) {
4850
println "**********************************"
4951
println "* Flavor aware sentry properties *"
5052
println "**********************************"
@@ -57,7 +59,7 @@ gradle.projectsEvaluated {
5759
description = "upload debug symbols to sentry"
5860

5961
def propertiesFile = "$reactRoot/android/sentry.properties";
60-
if (project.hasProperty("flavoraware")) {
62+
if (config.flavorAware) {
6163
propertiesFile = "$reactRoot/android/sentry-$variant"+".properties"
6264
println "For $variant using: $propertiesFile"
6365
} else {
@@ -76,12 +78,12 @@ gradle.projectsEvaluated {
7678
def args = [
7779
cliExecutable
7880
];
79-
if (project.hasProperty("sentryloglevel")) {
81+
if (config.logLevel) {
8082
args.push("--log-level");
81-
args.push(sentryloglevel);
83+
args.push(config.logLevel);
8284
}
8385

84-
if (project.hasProperty("flavoraware")) {
86+
if (config.flavorAware) {
8587
args.push("--url");
8688
args.push(sentryProps.get("defaults.url"));
8789
args.push("--auth-token");
@@ -97,7 +99,7 @@ gradle.projectsEvaluated {
9799
args.push("--release");
98100
args.push(releaseName);
99101

100-
if (project.hasProperty("flavoraware")) {
102+
if (config.flavorAware) {
101103
args.push("--org");
102104
args.push(sentryProps.get("defaults.org"));
103105
args.push("--project");
@@ -109,7 +111,7 @@ gradle.projectsEvaluated {
109111
args.add(versionCode);
110112
}
111113

112-
if (project.hasProperty("sentryloglevel")) {
114+
if (config.logLevel) {
113115
println args
114116
}
115117
if (Os.isFamily(Os.FAMILY_WINDOWS)) {

0 commit comments

Comments
 (0)