xRyul / obsidian-image-converter

⚡️ Convert and compress images from one format to another by drag'n'dropping or pasting files into the note.
MIT License
111 stars 11 forks source link

BUG: time format has 3 extra digits #30

Open blumenschwein opened 7 months ago

blumenschwein commented 7 months ago

When using auto rename, the generated file name has a suffix which is supposed to have the format YYYYMMDDHHMMSS, but I got three more digits. For example, in the file name my_note-2023-10-20231021102417842.jpg, "842" is the three extra digits. Is there a way to remove them?

Or even better: Is it possible to use regular expression to specify the format of the converted file name? Thanks a lot.

xRyul commented 6 months ago

Hey, thanks for checking out the plugin.

In current implementation the correct output should be in: YYYYMMDDHHmmssSSS so the 3 digits at the end are actually correct, and documentation is simply wrong - I gonna have to update it 🙏 With the latest release 1.1.7 , the milliseconds are needed for multi-drop to work correctly e.g.: to prevent having files with the same name

Support for various naming conventions/formats is currently WIP. Although, I will add "regular expression to specify the format of the converted file name" to my to-do list 🎉