mirror of
git://github.com/kovidgoyal/calibre.git
synced 2025-12-21 11:36:24 +01:00
Add a tweak that controls whether new book tags are applied when copying a book to another library
This commit is contained in:
commit
adcf9e2f16
2 changed files with 7 additions and 2 deletions
|
|
@ -105,3 +105,8 @@
|
|||
# case. 'MySearch' and 'mysearch' are the same term.
|
||||
grouped_search_terms = {}
|
||||
|
||||
|
||||
# Set this to True (not 'True') to ensure that tags in 'Tags to add when adding
|
||||
# a book' are added when copying books to another library
|
||||
add_new_book_tags_when_importing_books = False
|
||||
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@
|
|||
from calibre.gui2.actions import InterfaceAction
|
||||
from calibre.gui2 import error_dialog, Dispatcher
|
||||
from calibre.gui2.dialogs.progress import ProgressDialog
|
||||
from calibre.utils.config import prefs
|
||||
from calibre.utils.config import prefs, tweaks
|
||||
|
||||
class Worker(Thread):
|
||||
|
||||
|
|
@ -67,7 +67,7 @@ def doit(self):
|
|||
self.add_formats(identical_book, paths, newdb, replace=False)
|
||||
if not added:
|
||||
newdb.import_book(mi, paths, notify=False, import_hooks=False,
|
||||
apply_import_tags=False)
|
||||
apply_import_tags=tweaks['add_new_book_tags_when_importing_books'])
|
||||
co = self.db.conversion_options(x, 'PIPE')
|
||||
if co is not None:
|
||||
newdb.set_conversion_options(x, 'PIPE', co)
|
||||
|
|
|
|||
Loading…
Reference in a new issue