mirror of
https://github.com/platformio/platformio-core.git
synced 2025-07-30 10:07:14 +02:00
Use os.environ to detect CI system
This commit is contained in:
@ -176,7 +176,7 @@ def change_filemtime(path, time):
|
|||||||
|
|
||||||
|
|
||||||
def is_ci():
|
def is_ci():
|
||||||
return os.getenv("CI", "").lower() == "true"
|
return os.environ.get("CI", "").lower() == "true"
|
||||||
|
|
||||||
|
|
||||||
def exec_command(*args, **kwargs):
|
def exec_command(*args, **kwargs):
|
||||||
@ -189,8 +189,7 @@ def exec_command(*args, **kwargs):
|
|||||||
default = dict(
|
default = dict(
|
||||||
stdout=subprocess.PIPE,
|
stdout=subprocess.PIPE,
|
||||||
stderr=subprocess.PIPE,
|
stderr=subprocess.PIPE,
|
||||||
shell=system() == "Windows",
|
shell=system() == "Windows"
|
||||||
env=os.environ
|
|
||||||
)
|
)
|
||||||
default.update(kwargs)
|
default.update(kwargs)
|
||||||
kwargs = default
|
kwargs = default
|
||||||
|
Reference in New Issue
Block a user