From 76b9b3a11dc78f8ceefe81c9444c6387c042eb01 Mon Sep 17 00:00:00 2001 From: sio13 <33530405+sio13@users.noreply.github.com> Date: Fri, 22 May 2020 12:00:00 +0200 Subject: [PATCH] Update serial_ext.py - replaced with oneliner - removed default arguments --- tools/idf_py_actions/serial_ext.py | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/tools/idf_py_actions/serial_ext.py b/tools/idf_py_actions/serial_ext.py index 37a2e166c..ea20b9dad 100644 --- a/tools/idf_py_actions/serial_ext.py +++ b/tools/idf_py_actions/serial_ext.py @@ -85,12 +85,7 @@ def action_extensions(base_actions, project_path): monitor_args += ["-p", args.port] if not monitor_baud: - if os.getenv("IDF_MONITOR_BAUD"): - monitor_baud = os.getenv("IDF_MONITOR_BAUD", None) - elif os.getenv("MONITORBAUD"): - monitor_baud = os.getenv("MONITORBAUD", None) - else: - monitor_baud = project_desc["monitor_baud"] + monitor_baud = os.getenv("IDF_MONITOR_BAUD") or os.getenv("MONITORBAUD") or project_desc["monitor_baud"] monitor_args += ["-b", monitor_baud] monitor_args += ["--toolchain-prefix", project_desc["monitor_toolprefix"]]