We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1e3a341 commit 0ab5f6aCopy full SHA for 0ab5f6a
1 file changed
resultParser.py
@@ -1,4 +1,4 @@
1
-import sys, json
+import sys, json, os
2
3
def print_error_message(result):
4
error_message = ""
@@ -32,9 +32,13 @@ def print_failed_checks(output):
32
failed_checks = False
33
for result in output.get("result"):
34
failed_checks = print_error_message(result)
35
+ failBuild = os.getenv("failBuild", "true").lower() == "true"
36
if failed_checks:
- exit(-1)
37
-
+ if failBuild :
38
+ print("Pipeline status will be - Failed")
39
+ exit(-1)
40
+ else:
41
+ print("Pipeline status will be - Successful")
42
43
# Press the green button in the gutter to run the script.
44
if __name__ == '__main__':
0 commit comments