Open Kayizoku opened 2 years ago
I believe giving users customization options of how the list is displayed will solve this issue (similar to heading customization options). It is a lot of work to provide these options, perhaps one day when I am working on doing major update for LogManager inside the scripts.
Yup, my thoughts exactly. So take your time. I'll be looking forward to all future updates :)
Hi @Kayizoku, the changes are done in 2044e4397320943f38960d1b99cf4d0c59808a4b, however it is for SimpleBookmark, I will later migrate it to the other scripts.
The update is very big, I changed tons of things. Along with the update this issue is resolved, you can add any date format to the list (you must update both lua script and conf).
in list_content_text
you can simply add %dt%
to add the date and time exactly how it is added.
Very simple example:
list_content_text = '%number%. %dt% %name%%0_duration%%duration%%0_keybind%%keybind%%0_group%%group%%1_group%'
Example utilizing only "dt_"format%"%" (partially backward compatible with old dates saves in log)
list_content_text = '%number%. (%dt_%x% %dt_%H%:%dt_%M%) %name%%0_duration%%duration%%0_keybind%%keybind%%0_group%%group%%1_group%'
Advanced example utilizes both 0dt variables and %dt"format%"%. formatting (fully backward compatibile with old date formatting saved in log files)
list_content_text = '%number%.%0_dt%%dt_%x%%1_dt%%dt_%H%%2_dt%%dt_%M%%3_dt% %path%%0_duration%%duration%%0_keybind%%keybind%%0_group%%group%%1_group%'
list_content_variables=[ ["0_duration", " 🕒 "], ["0_keybind", " ⌨ "], ["0_group", " 🖿 "], ["0_dt", " ("], ["1_dt", " "], ["2_dt", ":"], ["3_dt", ")"] ]
Play around with this update, let me know your feedback
There are aspects that works for me and others that don't.
Here are bookmarks that have been untouched since last update. I didn't try to bookmark them again.
However, here's one item I tried to bookmark again, as you can see it messes up the date and gives some weird values while excluding day.
For some reason, this only happens after I have "%dt%" variable in the list_content_text. it won't retain the proper values for new items that are bookmarked. But the old ones are shown properly with the day and date. In any case, I appreciate implementing this, it really enrichens my experience with SimpleBookmark and I cannot wait to see it with the other scripts as well.
For some reason, this only happens after I have "%dt%" variable in the list_content_text. it won't retain the proper values for new items that are bookmarked. But the old ones are shown properly with the day and date. In any case, I appreciate implementing this, it really enrichens my experience with SimpleBookmark and I cannot wait to see it with the other scripts as well.
Yes, this is the expected behavior, because this is the new format for date (in the log file date is saved like this). This new format allowed me to create %dt_"format"% variable. So, you can make the date in any format you like. (This is only applicable for dates with the new format).
Try to log many new entries and use the below so you see the difference:
list_content_text = '%number%. (%dt_%x% %dt_%H%:%dt_%M%) %name%%0_duration%%duration%%0_keybind%%keybind%%0_group%%group%%1_group%'
Overall, this is the expected behavior which permits for date format customization.
Ah, I see, then everything is working as it should, I tried using dt_format and that gave me the desired effect I wanted :)
The title is self-explanatory. I want to know when I accessed a file last time. Thought it would be another cool addition to an already great script set