Allow import or sort single files
This commit is contained in:
parent
16e62cd451
commit
ed9fd7cc21
|
@ -361,7 +361,7 @@ class Paths:
|
||||||
:return: Path path
|
:return: Path path
|
||||||
"""
|
"""
|
||||||
if not path.exists():
|
if not path.exists():
|
||||||
self.log.error(f'Directory {path} does not exist')
|
self.log.error(f'Path {path} does not exist')
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
|
|
||||||
return path
|
return path
|
||||||
|
|
|
@ -718,6 +718,11 @@ class Medias:
|
||||||
"""Get paths"""
|
"""Get paths"""
|
||||||
for src_dir in src_dirs:
|
for src_dir in src_dirs:
|
||||||
src_dir = self.paths.check(src_dir)
|
src_dir = self.paths.check(src_dir)
|
||||||
|
|
||||||
|
if src_dir.is_file():
|
||||||
|
yield src_dir.parent, src_dir
|
||||||
|
continue
|
||||||
|
|
||||||
paths = self.paths.get_paths_list(src_dir)
|
paths = self.paths.get_paths_list(src_dir)
|
||||||
|
|
||||||
# Get medias and src_dirs
|
# Get medias and src_dirs
|
||||||
|
|
Loading…
Reference in New Issue