Added --jpeg-ext, implements #330

This commit is contained in:
Rhet Turnbull
2021-01-10 09:44:42 -08:00
parent ee2750224a
commit 55c088eea2
8 changed files with 182 additions and 22 deletions

18
utils/README.md Normal file
View File

@@ -0,0 +1,18 @@
# Utils
These are various utilities used in my development workflow. They may or may not be useful to you if you're working on osxphotos. If using the AppleScripts to get data from Photos, I highly recommend the excellent [FastScripts](https://redsweater.com/fastscripts/) from Red Sweater Software.
## Files
|File | Description |
|-----|-------------|
|build_help_table.py| Builds the template substitutions table used in main README.md |
|check_uuid.py| Use with output file created by dump_photo_info.scpt to check ouput of osxphotos vs what Photos reports|
|copy_uuid_to_clipboard.applescript| Copy UUID of selected photo in Photos to the Clipboard|
|dump_photo_info.applescript| Dumps UUID and other info about every photo in Photos.app to a test file; see check_uuid.py|
|dump_photo_info.scpt| Compiled version of dump_photo_info.applescript|
|gen_face_test_data.py| Generate test data for test_faceinfo.py|
|generate_search_info_test_data.py | Create the test data needed for test_search_info_10_15_7.py|
|get_photo_info.applescript| Displays UUID and other info about selected photos, useful for debugging|
|get_photo_info.scpt| Compiled version of above|
|write_uuid_to_file.applescript| Writes the UUIDs of selected images in Photos to a text file; can generate input for --uuid-from-file|

View File

@@ -0,0 +1,20 @@
-- Copies UUID of selected photo to the clipboard, if more than one selection, copies uuid from the last item
-- Useful for debugging with osxphotos
tell application "Photos"
set uuid to ""
set theSelection to selection
repeat with theItem in theSelection
set uuid to ((id of theItem) as text)
set oldDelimiter to AppleScript's text item delimiters
set AppleScript's text item delimiters to "/"
set theTextItems to every text item of uuid
set uuid to first item of theTextItems
set AppleScript's text item delimiters to oldDelimiter
end repeat
set the clipboard to uuid
end tell