I have some custom settings, and that can be done by placing a custom file in the src folder.
Works fine, no problems there.
But... with every update of the library this Custom_ESP_Mail_FS.h gets deleted, while the library clearly states:
"This Custom_ESP_Mail_FS.h will not change or overwrite when update the library."
Annoying when you have to reflash a bunch of boards again.
So who do I blame. The IDE (2.3.3) or the Library (3.4.22).
Leo..
Just tried downgrading and upgrading.
The IDE deleted the read-only file in both cases.
The main ESP_Mail_Client library folder and everything in it has a current date,
so the IDE deletes the whole library, before replacing it with a new one.
If I store that custom file anywhere in the top folder, it will be gone.
Leo..
If you're on a Linux box, you can try setting the 'i' attribute on the file with chattr. From man chattr:
A file with the 'i' attribute cannot be modified: it cannot be deleted or renamed, no link can be created to this file, most of the file's metadata can not be modified, and the file can not be opened in write mode. Only the superuser or a process possessing the CAP_LINUX_IMMUTABLE capability can set or clear this attribute.
I have this set on all of my local desktop icons to prevent absentmindedly deleting one when I don't notice it's selected.
Win11.
Tried to add security permissions to deny full control, but the IDE still deletes that file.
This is taking too much time. I just have to keep a close eye on updates.
Leo..