BookBrowser icon indicating copy to clipboard operation
BookBrowser copied to clipboard

Add auto refresh

Open pgaskin opened this issue 8 years ago • 6 comments

Automatically reload books when added or removed.

pgaskin avatar Jun 26 '17 02:06 pgaskin

Added reload on SIGUSR1: 355b60589106f99a5975f27a945e121f8ebc1353

pgaskin avatar Aug 31 '17 19:08 pgaskin

Because of issues with https://github.com/fsnotify/fsnotify, I may just resort to polling.

pgaskin avatar Oct 17 '17 11:10 pgaskin

I guess you never implemented this? Would be a nice feature to have.

realper avatar Oct 04 '18 20:10 realper

I'm probably going to implement this in the next version the way I did in repogen.

https://github.com/geek1011/repogen/blob/80e716da1180b084116410b1c65c98534fab636e/main.go#L75-L133

The reasons why I haven't done it yet is:

  • I needed to make sure I don't run out of file descriptors or other things like that for large libraries
  • I needed to make sure I don't read from an ebook if it is, lets say, still being copied
  • I needed to find an efficient way to check for changes, even if the file size or date is the same
  • I needed to make sure that nothing will put BookBrowser into an endless refresh loop
  • I needed to make sure this works on Windows, and I rarely use it anymore
  • I wanted to test this before implementing it

pgaskin avatar Oct 04 '18 20:10 pgaskin

Of course, I can see it's pretty complicated. I really like your book server, so I just thought I would let you know, this would be a nice feature to have. If you need further testing on Windows, let me know, since that's what I use.

realper avatar Oct 04 '18 22:10 realper

Yep, no problem.

pgaskin avatar Oct 05 '18 01:10 pgaskin