Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Library Management

Notices

Reply
 
Thread Tools Search this Thread
Old 08-21-2023, 08:04 PM   #1
thestraycat
Member
thestraycat began at the beginning.
 
Posts: 12
Karma: 10
Join Date: Aug 2023
Device: Kindle
Is it possible to have 2 librarys and a different watch folder for each library?

I have 3 different calibre librarys for convenience for me and my GF and a friend

/Library_Me
/Library_GF
/ibrary_Friend


However, I want seperate watch folders that feed specifically processing tasks into each of these librarys via their own watch folders.

Watchfolder1 > /Library_Me
Watchfolder2 > /Library_GF
Watchfolder2 > /Library_Friend

Is it possible to do this in calibre? I wanted to avoid running 3 instances of Calibre as it consumes about 3gb of ram at idle and each watch folder would have different automatic processing tasks.
thestraycat is offline   Reply With Quote
Old 08-21-2023, 11:06 PM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,353
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
No you can have only a single watch folder. Run the calibre server and use the calibredb command to connect to it and add books via a script instead. Then your script can run on as many watch folders as you like and do whatever processing you like.
kovidgoyal is offline   Reply With Quote
Advert
Old 08-21-2023, 11:09 PM   #3
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 21,725
Karma: 29711016
Join Date: Mar 2012
Location: Sydney Australia
Device: none
What is a 'watch folder'?

If you mean a calibre Autoadd folder then the JobSpy plugin has an option in its Configuration settings: Tweak for Per-Library: 'Auto-Add Directory':

Make sure you read the tool-tip, it requires further settings in Plugin Tweaks.

BR
BetterRed is offline   Reply With Quote
Old 08-23-2023, 08:33 PM   #4
thestraycat
Member
thestraycat began at the beginning.
 
Posts: 12
Karma: 10
Join Date: Aug 2023
Device: Kindle
@BetterRed - Thanks for the tip! Your plugin looks incredibly powerful and really helps extend the core functionality! It Does exactly what i needed. However i have run into a slight snag with it. I have 5 librarys now that are all configured with their own auto-add folder. I've enabled and am using the the followings configs in tweaks > plugins

- Tweaks for per Library - 'Auto-Add Directory'
- Tweaks for per Library - 'Save to Directory'

However in my testing, i copied a .mobi book into each of the 5 watched folders to see if it would automatically import it and noticed that calibre would only import the book if i manually switched over to each library. That seemed to kickstart the auto-adding.

I was under the impression that calibre would be watching for books to land in these folders on a timer of say 5 minutes or so and that it would move the books without needing me to select each library to complete the auto-adding.

Is there an option i need to enable to always watch these folders?

Newbie here, so if you need me to do anything just ask and i'll try and test.
thestraycat is offline   Reply With Quote
Old 08-23-2023, 10:02 PM   #5
thestraycat
Member
thestraycat began at the beginning.
 
Posts: 12
Karma: 10
Join Date: Aug 2023
Device: Kindle
@BetterRed - Thank you so much for the tip! Your plugin is amazing and really extends the core functionaity! It had just the functionality i was looking for and i've nearly got it working as planned. However i hit a minor snag.

I now have 5 librarys. And have a watch folder and seperate library destination folders for each one.

I've added config for the following 2 tweaks:

Tweaks for per Library - 'Auto-Add Directory'
Tweaks for per Library - 'Save to Directory'

However the auto-add function only runs a job when i quick-switch over to each library from within calibre.

I'm assuming there would be a background timer process that checks these watchfolders automatically every day 5 minutes and processes and files found in the folders however in my experience i have to toggle to each library database for it to run.

Am i missing some config? If you need me to test/check anything please let me know, i'm a newb but more than happy to help where i can?
thestraycat is offline   Reply With Quote
Advert
Old 08-24-2023, 02:15 AM   #6
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 21,725
Karma: 29711016
Join Date: Mar 2012
Location: Sydney Australia
Device: none
@thestraycat - got your message - the reason your posts are going into the moderation queue is as you suggested: a low post count - its an anti-spam measure. You need to get your post count above 10. There are some "Silly" threads in The Lounge, post some replies in there.

Regarding the JobSpy Per library Autoadd folder feature. Firstly, JobSpy is not 'my' plugin, its DaltonST's plugin. Secondly I don't use that feature I just know its there. If you post your queries in the JobSpy thread, DaltonST should respond - post a link to this thread so he has the context.

Good luck - BR
BetterRed is offline   Reply With Quote
Old 08-24-2023, 07:42 AM   #7
Comfy.n
want to learn what I want
Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.
 
Posts: 1,611
Karma: 7891011
Join Date: Sep 2020
Device: none
@BR - did you notice that DaltonST's last recent posts here are from almost two months ago? Maybe he's on vacation.
Comfy.n is offline   Reply With Quote
Old 08-24-2023, 07:02 PM   #8
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 21,725
Karma: 29711016
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by Comfy.n View Post
@BR - did you notice that DaltonST's last recent posts here are from almost two months ago? Maybe he's on vacation.
Yes I know it's been a while, IIRC there have been extended absences in the past, perhaps he goes on retreat every year or two.

At a guess I'd say JS doesn't watch any folders, and certainly not multiple folders simultaneously. The tooltip (attached) implies that the folder path designated for a library in the job_spy_auto_add_directory plugin tweak is copied into the global calibre autoadd preference when a library is opened (switched to).

BR
Attached Thumbnails
Click image for larger version

Name:	Screenshot 2023-08-25 085213.jpg
Views:	86
Size:	185.6 KB
ID:	203336  

Last edited by BetterRed; 08-24-2023 at 08:24 PM.
BetterRed is offline   Reply With Quote
Old 09-29-2023, 07:48 PM   #9
thestraycat
Member
thestraycat began at the beginning.
 
Posts: 12
Karma: 10
Join Date: Aug 2023
Device: Kindle
@kovidgoyal

When using a bash script to add books there seems no argument with caliberedb to delete book after successful import... Also there dosnt seem a way of getting the errorcode of the 'calibredb add' command... for example if i try and add a duplicate book to my library via 'calibre add' it will complain that i rightly need to use the 'duplicates' or 'automerge' options but the command still finishes with an errorcode 0 (successful)

Obviously, if i'm to remove the source book from my watchfolders in my script i need to know whether the book actually successfully added or not prior to deleting it... any ideas?
thestraycat is offline   Reply With Quote
Old 09-29-2023, 10:29 PM   #10
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,353
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Use rm to delete files. You can check if a book was added using calibredb list, all it before and after adding and check the highest id. Although calibredb will never fail if you pass it --duplicates barring bugs so there is no need to check.
kovidgoyal is offline   Reply With Quote
Old 10-04-2023, 11:00 AM   #11
thestraycat
Member
thestraycat began at the beginning.
 
Posts: 12
Karma: 10
Join Date: Aug 2023
Device: Kindle
Thanks i'll have another go!
thestraycat is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Changing Library Folder miguel_roboso Calibre 30 10-06-2017 01:23 AM
New library in 'offline' folder Rob_W Library Management 11 04-13-2015 06:53 AM
Cleaning up my library and my library folder kaufman Library Management 5 01-26-2014 02:18 AM
Auto Merge Watch Folder? Turtle91 Library Management 2 01-13-2013 06:19 PM
Can't change library folder Matsendrasana Library Management 19 11-21-2012 05:00 AM


All times are GMT -4. The time now is 08:34 AM.


MobileRead.com is a privately owned, operated and funded community.