From 8c30c359d7df7c566c611f47dc589ee5ddfc7401 Mon Sep 17 00:00:00 2001 From: Thea Flowers Date: Sat, 13 Feb 2021 18:38:26 -0500 Subject: [PATCH] Fix factory setup publish --- factory/factory_setup.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/factory/factory_setup.py b/factory/factory_setup.py index 2d041ed..dd6ea7c 100644 --- a/factory/factory_setup.py +++ b/factory/factory_setup.py @@ -53,8 +53,8 @@ def deploy_circuitpython_code(destination=None): print("Waiting for CIRCUITPY drive...") destination = wintertools.fs.wait_for_drive("CIRCUITPY") - print("Forcing BHB into repl (workaround for CircuitPython issue #3986)") - wintertools.circuitpython.force_into_repl(USB_DEVICE_ID) + print("Forcing BHB into repl (workaround for CircuitPython issue #3986)") + wintertools.circuitpython.force_into_repl(USB_DEVICE_ID) print("Cleaning temporary files from src directories...") wintertools.fs.clean_pycache(FIRMWARE_DIR) @@ -65,9 +65,10 @@ def deploy_circuitpython_code(destination=None): print("Copying files...") wintertools.fs.deploy_files(FILES_TO_DEPLOY, destination) - print("Done copying files, resetting...") - wintertools.circuitpython.reset_via_serial(USB_DEVICE_ID) - print("Done!") + if not destination: + print("Done copying files, resetting...") + wintertools.circuitpython.reset_via_serial(USB_DEVICE_ID) + print("Done!") def main():