From e568baad968749d5302831e922522139b19c4a0c Mon Sep 17 00:00:00 2001 From: Kai Vogelgesang Date: Thu, 10 Jul 2025 01:25:05 +0200 Subject: [PATCH] Exclude main.py from py -> mpy conversion --- pico/Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pico/Makefile b/pico/Makefile index beac495..c7ff872 100644 --- a/pico/Makefile +++ b/pico/Makefile @@ -1,7 +1,8 @@ SRC_DIR := src BUILD_DIR := build -SRC_FILES := $(wildcard $(SRC_DIR)/*.py) $(wildcard $(SRC_DIR)/**/*.py) +MAIN_PY := src/main.py +SRC_FILES := $(filter-out $(MAIN_PY), $(wildcard $(SRC_DIR)/*.py) $(wildcard $(SRC_DIR)/**/*.py)) BUILD_FILES := $(patsubst $(SRC_DIR)/%.py,$(BUILD_DIR)/%.mpy, $(SRC_FILES)) $(BUILD_DIR)/%.mpy: $(SRC_DIR)/%.py @@ -17,6 +18,7 @@ clean: .PHONY: deploy deploy: $(BUILD_FILES) + mpremote fs cp $(MAIN_PY) : mpremote fs cp -r $(BUILD_DIR)/* : .PHONY: purge