Added --has-raw to CLI query and export
This commit is contained in:
@@ -345,6 +345,11 @@ def query_options(f):
|
|||||||
is_flag=True,
|
is_flag=True,
|
||||||
help="Search for photos that are not panoramas.",
|
help="Search for photos that are not panoramas.",
|
||||||
),
|
),
|
||||||
|
o(
|
||||||
|
"--has-raw",
|
||||||
|
is_flag=True,
|
||||||
|
help="Search for photos with both a jpeg and RAW version",
|
||||||
|
),
|
||||||
o(
|
o(
|
||||||
"--only-movies",
|
"--only-movies",
|
||||||
is_flag=True,
|
is_flag=True,
|
||||||
@@ -724,6 +729,7 @@ def query(
|
|||||||
not_selfie,
|
not_selfie,
|
||||||
panorama,
|
panorama,
|
||||||
not_panorama,
|
not_panorama,
|
||||||
|
has_raw,
|
||||||
place,
|
place,
|
||||||
no_place,
|
no_place,
|
||||||
):
|
):
|
||||||
@@ -743,6 +749,7 @@ def query(
|
|||||||
edited,
|
edited,
|
||||||
external_edit,
|
external_edit,
|
||||||
uti,
|
uti,
|
||||||
|
has_raw,
|
||||||
from_date,
|
from_date,
|
||||||
to_date,
|
to_date,
|
||||||
]
|
]
|
||||||
@@ -836,6 +843,7 @@ def query(
|
|||||||
not_selfie=not_selfie,
|
not_selfie=not_selfie,
|
||||||
panorama=panorama,
|
panorama=panorama,
|
||||||
not_panorama=not_panorama,
|
not_panorama=not_panorama,
|
||||||
|
has_raw=has_raw,
|
||||||
place=place,
|
place=place,
|
||||||
no_place=no_place,
|
no_place=no_place,
|
||||||
)
|
)
|
||||||
@@ -993,6 +1001,7 @@ def export(
|
|||||||
not_selfie,
|
not_selfie,
|
||||||
panorama,
|
panorama,
|
||||||
not_panorama,
|
not_panorama,
|
||||||
|
has_raw,
|
||||||
directory,
|
directory,
|
||||||
place,
|
place,
|
||||||
no_place,
|
no_place,
|
||||||
@@ -1108,6 +1117,7 @@ def export(
|
|||||||
not_selfie=not_selfie,
|
not_selfie=not_selfie,
|
||||||
panorama=panorama,
|
panorama=panorama,
|
||||||
not_panorama=not_panorama,
|
not_panorama=not_panorama,
|
||||||
|
has_raw=has_raw,
|
||||||
place=place,
|
place=place,
|
||||||
no_place=no_place,
|
no_place=no_place,
|
||||||
)
|
)
|
||||||
@@ -1232,6 +1242,9 @@ def print_photo_info(photos, json=False):
|
|||||||
"hdr",
|
"hdr",
|
||||||
"selfie",
|
"selfie",
|
||||||
"panorama",
|
"panorama",
|
||||||
|
"has_raw",
|
||||||
|
"uti_raw",
|
||||||
|
"path_raw",
|
||||||
]
|
]
|
||||||
)
|
)
|
||||||
for p in photos:
|
for p in photos:
|
||||||
@@ -1273,6 +1286,9 @@ def print_photo_info(photos, json=False):
|
|||||||
p.hdr,
|
p.hdr,
|
||||||
p.selfie,
|
p.selfie,
|
||||||
p.panorama,
|
p.panorama,
|
||||||
|
p.has_raw,
|
||||||
|
p.uti_raw,
|
||||||
|
p.path_raw,
|
||||||
]
|
]
|
||||||
)
|
)
|
||||||
for row in dump:
|
for row in dump:
|
||||||
@@ -1328,6 +1344,7 @@ def _query(
|
|||||||
not_selfie=None,
|
not_selfie=None,
|
||||||
panorama=None,
|
panorama=None,
|
||||||
not_panorama=None,
|
not_panorama=None,
|
||||||
|
has_raw=None,
|
||||||
place=None,
|
place=None,
|
||||||
no_place=None,
|
no_place=None,
|
||||||
):
|
):
|
||||||
@@ -1516,6 +1533,9 @@ def _query(
|
|||||||
elif not_incloud:
|
elif not_incloud:
|
||||||
photos = [p for p in photos if not p.incloud]
|
photos = [p for p in photos if not p.incloud]
|
||||||
|
|
||||||
|
if has_raw:
|
||||||
|
photos = [p for p in photos if p.has_raw]
|
||||||
|
|
||||||
return photos
|
return photos
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user