build: add uninstall target to delete files on esp

This commit is contained in:
Laborratte5 2024-04-29 23:06:52 +02:00
parent 5a8c3abd49
commit 02dfb0450d
Signed by: Laborratte5
GPG key ID: 3A30072E35202C02

View file

@ -29,6 +29,13 @@ install: check src/*.mpy
$(AMPY) --port $(ESP_PORT) put $$f; \ $(AMPY) --port $(ESP_PORT) put $$f; \
done done
uninstall:
@echo $(filter-out /boot.py,$(shell $(AMPY) --port $(ESP_PORT) ls))
@for f in $(filter-out /boot.py,$(shell $(AMPY) --port $(ESP_PORT) ls)); do \
echo Deleting $$f; \
$(AMPY) --port $(ESP_PORT) rm $$f; \
done
clean: clean:
rm -rf src/__pycache__ rm -rf src/__pycache__
rm -f src/*.pyc rm -f src/*.pyc