fix stuff (stuff)
This commit is contained in:
parent
37c45e4c0a
commit
10dbcb42f1
@ -19,7 +19,6 @@ with open("metadata.json", "r") as f:
|
||||
|
||||
for placename in metadata.keys():
|
||||
read_path = f"{out_dir}{placename}/"
|
||||
write_path = f"{out_dir}photos.json"
|
||||
photos = [
|
||||
path.basename(photo).split('/')[-1] for photo in
|
||||
glob(read_path + "*")
|
||||
@ -31,7 +30,8 @@ for placename in metadata.keys():
|
||||
metadata[placename]["count"] = len(photos)
|
||||
metadata[placename]["photos"] = photos
|
||||
metadata[placename]["photos"].sort(key=lambda path: int(numbers.search(path).group(0)))
|
||||
with open(write_path, "w") as f:
|
||||
|
||||
with open(f"{out_dir}photos.json", "w") as f:
|
||||
dump(metadata, f)
|
||||
|
||||
def covers(overwrite=False):
|
||||
|
Loading…
x
Reference in New Issue
Block a user