Skip to content

Commit 856c1fc

Browse files
authored
Update pyzowe.py
Signed-off-by: Fernando Rijo Cedeno <37381190+zFernand0@users.noreply.github.com>
1 parent 2b6c054 commit 856c1fc

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

python/pyzowe/pyzowe.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
"""
2525
import subprocess
2626
import json
27+
import os
2728

2829

2930
class ZoweCallError(Exception):
@@ -82,8 +83,10 @@ def zowe(arguments: str):
8283
for job in zowe("zos-jobs list jobs"):
8384
print(f"Job {job['jobid']} has return code {job['retcode']}")
8485
"""
85-
86+
old_color = os.environ['FORCE_COLOR']
87+
os.environ['FORCE_COLOR'] = "0"
8688
zowe_command = "zowe " + arguments + " --rfj"
89+
os.environ['FORCE_COLOR'] = old_color
8790
try:
8891
completed_process = subprocess.run(
8992
zowe_command, shell=True, capture_output=True, check=True, encoding="utf8")

0 commit comments

Comments
 (0)