View Single Post
Old 12-30-2018, 05:12 AM   #1
Bertrand
Zealot
Bertrand began at the beginning.
 
Posts: 124
Karma: 10
Join Date: Dec 2008
Location: France
Device: None
Command line : adding books to the main library

Hi all

I add books in calibre with a batch file. It works well but I have a small glitch.

In the GUI, I have 2 libraries, let's say A (main library) and B.
Despite the fact that the main library is mentionned in the batch file, the books are always added to the last library I opened in the GUI.
If B was the last one, then they are added to B.
If A was the last one, then they are added to A (which is ok).

Not a big deal, when it happens, I just copy (and delete) from B to A, but I'd like to understand what's wrong with my code.

Here is a snippet of my batch file :
Code:
set source=D:\Epubs
:: Main library
set library=C:\Calibre
calibre-debug -s
calibredb add -d --library-path %library% %source%
The doc doesn't mention --library-path as a parameter for the add command, I think I found this somewhere in the forum.
Bertrand is offline   Reply With Quote