Skip to content

Commit 029c912

Browse files
committed
Comment and reorder the files creation.
1 parent 57ac916 commit 029c912

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

supervisor/shared/filesystem.c

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -127,10 +127,15 @@ bool filesystem_init(bool create_allowed, bool force_create) {
127127
if (res != FR_OK) {
128128
return false;
129129
}
130-
make_empty_file(&vfs_fat->fatfs, "/.metadata_never_index");
131-
make_empty_file(&vfs_fat->fatfs, "/.Trashes");
132-
make_empty_file(&vfs_fat->fatfs, "/.Trash-1000");
133130
make_empty_file(&vfs_fat->fatfs, "/.fseventsd/no_log");
131+
make_empty_file(&vfs_fat->fatfs, "/.metadata_never_index");
132+
133+
// Prevent storing trash on all OSes.
134+
make_empty_file(&vfs_fat->fatfs, "/.Trashes"); // MacOS
135+
make_empty_file(&vfs_fat->fatfs, "/.Trash-1000"); // Linux, XDG trash spec:
136+
// https://specifications.freedesktop.org/trash-spec/trashspec-latest.html
137+
138+
134139
#if CIRCUITPY_OS_GETENV
135140
make_empty_file(&vfs_fat->fatfs, "/settings.toml");
136141
#endif

0 commit comments

Comments
 (0)