Let the original ComicRack metadata be disabled
Ensure metadata styles can be overridden by other plugins
This commit is contained in:
parent
fd868d9596
commit
da373764e0
@ -12,6 +12,12 @@ from comictaggerlib.defaults import DEFAULT_REPLACEMENTS, Replacement, Replaceme
|
||||
def general(parser: settngs.Manager) -> None:
|
||||
# General Settings
|
||||
parser.add_setting("check_for_new_version", default=False, cmdline=False)
|
||||
parser.add_setting(
|
||||
"--disable-cr",
|
||||
default=False,
|
||||
action=argparse.BooleanOptionalAction,
|
||||
help="Disable the ComicRack metadata type",
|
||||
)
|
||||
|
||||
|
||||
def internal(parser: settngs.Manager) -> None:
|
||||
|
@ -96,6 +96,7 @@ class settngs_namespace(settngs.TypedNS):
|
||||
Auto_Tag__remove_archive_after_successful_match: bool
|
||||
|
||||
General__check_for_new_version: bool
|
||||
General__disable_cr: bool
|
||||
|
||||
Dialog_Flags__show_disclaimer: bool
|
||||
Dialog_Flags__dont_notify_about_this_version: str
|
||||
|
@ -223,6 +223,10 @@ class App:
|
||||
# config already loaded
|
||||
error = None
|
||||
|
||||
if self.config[0].General__disable_cr:
|
||||
if "cr" in comicapi.comicarchive.metadata_styles:
|
||||
del comicapi.comicarchive.metadata_styles["cr"]
|
||||
|
||||
if len(self.talkers) < 1:
|
||||
error = error = (
|
||||
"Failed to load any talkers, please re-install and check the log located in '"
|
||||
|
Loading…
Reference in New Issue
Block a user