fastlane-plugin-android_reporter 0.1.20 → 0.1.25
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3ff2cc9b5f89313105fad1f9b71ad518b26fca3ae709b4ec2360f2a4c4a220ae
|
4
|
+
data.tar.gz: 50cda79b62bfaa525b7d700ea8252c30fbe4edd5de69522fa6b78f66e1a857db
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b7bd569619369358b7a7641d23cf864634b7faca99780cc1807dabcfe0ed7cf5e86ea5dc0003114ce105d7d2ee7d659b737bc741b69f1eb11f8d9e6377b54243
|
7
|
+
data.tar.gz: 1d797d9de9112dabd5f3ef2f347a1954329f63df25878df77be872d0037458015292f2c6b4a7868f59ccb3e6e04dba59065f16839d6210790c48f18d1400ba9f
|
@@ -26,28 +26,30 @@ module Fastlane
|
|
26
26
|
isGradleErrorFileUploaded = false
|
27
27
|
|
28
28
|
# 1. Delete Previus Generated Files
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
29
|
+
if params[:is_delete_prev_files_enabled]
|
30
|
+
begin
|
31
|
+
File.open('logcat.txt', 'r') do |f|
|
32
|
+
File.delete(f)
|
33
|
+
end
|
34
|
+
rescue Errno::ENOENT
|
35
|
+
UI.message("Something Wrong When Delete Previus File [logcat.txt]")
|
36
|
+
end
|
36
37
|
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
38
|
+
begin
|
39
|
+
File.open('android-logs.txt', 'r') do |f|
|
40
|
+
File.delete(f)
|
41
|
+
end
|
42
|
+
rescue Errno::ENOENT
|
43
|
+
UI.message("Something Wrong When Delete Previus File [android-logs.txt]")
|
44
|
+
end
|
44
45
|
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
46
|
+
begin
|
47
|
+
File.open('android-error-logs.txt', 'r') do |f|
|
48
|
+
File.delete(f)
|
49
|
+
end
|
50
|
+
rescue Errno::ENOENT
|
51
|
+
UI.message("Something Wrong When Delete Previus File [android-error-logs.txt]")
|
52
|
+
end
|
51
53
|
end
|
52
54
|
|
53
55
|
# 0. Checkout git to Current Branch to Run Tests on the Current Branch
|
@@ -87,19 +89,15 @@ module Fastlane
|
|
87
89
|
# 2. List All Available AVD's in The Device
|
88
90
|
# 3. Run the Target AVD Name From Params
|
89
91
|
if params[:avd_name].to_s.length > 0
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
sh(android_sdk_path + "/emulator/emulator", "-avd", avd_name)
|
95
|
-
end
|
92
|
+
UI.message("Android Reporting Started to Run AVD : (" + avd_name + ")")
|
93
|
+
sh(android_sdk_path + "/tools/bin/avdmanager", "list", "avd")
|
94
|
+
sh("cd", android_sdk_path)
|
95
|
+
sh(android_sdk_path + "/emulator/emulator", "-avd", avd_name)
|
96
96
|
end
|
97
97
|
|
98
98
|
# 4. Clear the Logcat Server Before Start
|
99
99
|
if params[:generate_adb_file]
|
100
|
-
|
101
|
-
sh("adb logcat -c")
|
102
|
-
end
|
100
|
+
sh("adb logcat -c")
|
103
101
|
end
|
104
102
|
|
105
103
|
# 5. Start Clean Task with Target UI Task
|
@@ -123,6 +121,7 @@ module Fastlane
|
|
123
121
|
|
124
122
|
begin
|
125
123
|
sh("adb logcat -d > logcat.txt kill-server")
|
124
|
+
sh("adb kill-server")
|
126
125
|
rescue => error
|
127
126
|
if error
|
128
127
|
UI.error("Something Error with Logcat Debug Report File")
|
@@ -137,38 +136,35 @@ module Fastlane
|
|
137
136
|
rescue
|
138
137
|
UI.error("Gradle Task Finished With Error ...")
|
139
138
|
if params[:generate_adb_file]
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
puts error.backtrace
|
149
|
-
end
|
139
|
+
begin
|
140
|
+
sh("adb logcat -e > logcat.txt kill-server")
|
141
|
+
rescue => error
|
142
|
+
if error
|
143
|
+
UI.error("Something Error with Logcat Error Report File")
|
144
|
+
end
|
145
|
+
puts error.message
|
146
|
+
puts error.backtrace
|
150
147
|
end
|
151
148
|
end
|
152
149
|
end
|
153
150
|
|
154
151
|
# 7. Generate Gradle Tasks (Failed and Success Files)
|
155
152
|
if params[:generate_gradle_files]
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
end
|
153
|
+
UI.message([
|
154
|
+
"Android Reporting Started to Generate Gradle Reports Files",
|
155
|
+
"Gradle Success Debug File : android-logs.txt",
|
156
|
+
"Gradle Failed Debug File : android-error-logs.txt"
|
157
|
+
])
|
158
|
+
|
159
|
+
begin
|
160
|
+
sh("./gradlew build > android-logs.txt 2> android-error-logs.txt -Dhttp.socketTimeout=60000 -Dhttp.connectionTimeout=60000 -Dorg.gradle.daemon.idletimeout=60000")
|
161
|
+
sh("./gradlew --stop")
|
162
|
+
rescue => error
|
163
|
+
if error
|
164
|
+
UI.error("Something Error with Generate Gradle Files")
|
165
|
+
end
|
166
|
+
puts error.message
|
167
|
+
puts error.backtrace
|
172
168
|
end
|
173
169
|
end
|
174
170
|
|
@@ -344,6 +340,13 @@ module Fastlane
|
|
344
340
|
optional: true,
|
345
341
|
type: Boolean
|
346
342
|
),
|
343
|
+
FastlaneCore::ConfigItem.new(
|
344
|
+
key: :is_delete_prev_files_enabled,
|
345
|
+
env_name: "ANDROID_GENERATED_PREV_FILES_ENABLED",
|
346
|
+
description: "",
|
347
|
+
optional: true,
|
348
|
+
type: Boolean
|
349
|
+
),
|
347
350
|
FastlaneCore::ConfigItem.new(
|
348
351
|
key: :slack_api_key,
|
349
352
|
env_name: "SLACK_API_TOKEN",
|