Look for a volume with a name like CIRCUITPY (the default for CircuitPython). The full
path to the volume is the /Volumes/CIRCUITPY path.
Now follow
the steps from this
hidden files from being created on the board:
mdutil -i off /Volumes/CIRCUITPY
cd /Volumes/CIRCUITPY
rm -rf .{,_.}{fseventsd,Spotlight-V*,Trashes}
mkdir .fseventsd
touch .fseventsd/no_log .metadata_never_index .Trashes
cd -
Replace /Volumes/CIRCUITPY in the commands above with the full path to your
board's volume if it's different. At this point all the hidden files should be cleared from
the board and some hidden files will be prevented from being created.
Alternatively, with CircuitPython 4.x and above, the special files and folders
mentioned above will be created automatically if you erase and reformat the
filesystem. WARNING: Save your files first! Do this in the REPL:
>>> import storage
>>> storage.erase_filesystem()
However there are still some cases where hidden files will be created by MacOS. In
particular if you copy a file that was downloaded from the internet it will have special
metadata that MacOS stores as a hidden file. Luckily you can run a copy command
from the terminal to copy files without this hidden metadata file. See the steps below.
Copy Files on MacOS Without Creating Hidden Files
Once you've disabled and removed hidden files with the above commands on macOS
you need to be careful to copy files to the board with a special command that
prevents future hidden files from being created. Unfortunately you cannot use drag
and drop copy in Finder because it will still create these hidden extended attribute
files in some cases (for files downloaded from the internet, like Adafruit's modules).
To copy a file or folder use the -X option for the cp command in a terminal. For
example to copy a file_name.mpy file to the board use a command like:
cp -X file_name.mpy /Volumes/CIRCUITPY
©Adafruit Industries
question () to run these terminal commands that stop
Page 112 of 263
Need help?
Do you have a question about the ESP32-S3 and is the answer not in the manual?