I am working my way through a number of tutorials and switching between PlatformIO and Aduino IDE.
Do I need to clear the ESP8266 file system before starting each new project? If so how is this done?
Is there a simple way to read what is currently in the LittleFS system?
You don’t need to clear the file system before starting each project. If you upload files with the same name, they will be overwritten.
To list all files in SPIFFS or LittleFS, you can run the code shown here: https://www.esp8266.com/viewtopic.php?p=87718#p87718
Replace SPIFFS with LittleFS if you’re using LittleFS.
This tutorial explains very well how to list and delete files: https://techtutorialsx.com/2019/02/24/esp32-arduino-removing-a-file-from-the-spiffs-file-system/
If you’re using the ESP8266, initialize SPIFFS like this:
Or little FS like this:
I hope this helps.