JuanJakobo / Pocketbook-Nextcloud-Client

Nextcoud Client for Pocketbook
GNU General Public License v3.0
111 stars 5 forks source link

How to exclude multiple folders using regex? #36

Open vores8 opened 1 year ago

vores8 commented 1 year ago

Hi and thanks for the great software.

I am trying to use "Exclude and hide items" to hide some folders that are unrelated to the reader. I have several folders named like "backup", "cache" etc. My initial guess was to put just backup in the Folder-Regex: field to do the job - unfortunately it does not work, "backup" folder is still visible. Do I need to use any magic to achieve the result?

Thanks in advance

JuanJakobo commented 1 year ago

Hi @vores8, Thank you. The regex compares it to the complete file name. Therefore if you want to hide all backup and caches folder in each directory you should put: .*backup.*|.*cache.* If you just want to hide certain items you have to put the complete path of the folder. Does this work for you?

vores8 commented 1 year ago

Juan hi

Thanks for the reply. Yes, it works (partially), thanks again.

There is still a minor problem. Cause I have a number folders to exclude, I decided to reverse the conditions and put .*books.* in the folder regex field and checked "Only include matching" checkbox. Is my understanding correct that it should hide all files except files and subfolders in the "books" folder? (and yes, it hides all the folders except books) This resulted in two problems

Thanks in advance

JuanJakobo commented 1 year ago

Hi, the files should be visible with the new release. Test it please. You should delete all filters, reload the folders and then apply the filters again.

vores8 commented 1 year ago

Juan hi

Yes, files are visible now, thanks for the fix. But unfortunately the other issue still persists

I cannot open any subfolder under books folder with the message "Not implemented to look at local folder", although if i remove the filter, i can open these subfolders without problem.

Thanks in advance

P.S. Also with the new version, even after I delete all the filters and actualized "books" folder, subfolders of the "books" folder cannot be opened with the message "Not implemented to look at local folder". I fixed this by deleting /system/config/data.db file, not sure if this is the correct way