mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-04-20 16:25:04 +02:00
calibredb check_library: Do not create empty library if user specifies incorrect path
This commit is contained in:
parent
49ba0a991b
commit
dd01e7448f
1 changed files with 4 additions and 0 deletions
|
|
@ -1211,6 +1211,10 @@ def print_one(checker, check):
|
|||
for i in list:
|
||||
print ' %-40.40s - %-40.40s'%(i[0], i[1])
|
||||
|
||||
if not LibraryDatabase.exists_at(dbpath):
|
||||
prints('No library found at', dbpath, file=sys.stderr)
|
||||
raise SystemExit(1)
|
||||
|
||||
db = LibraryDatabase(dbpath)
|
||||
checker = CheckLibrary(dbpath, db)
|
||||
checker.scan_library(names, exts)
|
||||
|
|
|
|||
Loading…
Reference in a new issue