You have to add two shortcuts to Calibre for this to work.
In Calibre open Preferences and then open Shortcuts.
In the “Search for a shortcut by name” write copy and press enter.
For “Copy metadata” create a shortcut: Option + C
And for “Copy URL to show book in calibre” create a shortcut: Command + C
The Calibre scripts for Hook
Get Name:
set the clipboard to ""
tell application "System Events"
repeat 10 times
keystroke "c" using {option down}
delay 0.1
set t to (the clipboard as text)
if t is not missing value and t is not equal to "" then
exit repeat
end if
end repeat
end tell
set title to paragraph 1 of t
set author to paragraph 3 of t
set text item delimiters to {": "}
return text item 2 of title & " by " & text item 2 of author
Get Address:
set the clipboard to ""
tell application "System Events"
repeat 10 times
keystroke "c" using {command down}
delay 0.1
set t to (the clipboard as text)
if t is not missing value and t is not equal to "" then
exit repeat
end if
end repeat
end tell
return t
Yes, I briefly mentioned that in the other Calibre thread a while ago, but you gave a good explanation of them yesterday. I’m not using them in practice as most of my stuff own Calibre is PDFs, which I prefer to access and deep-link to in other ways – I’m not a fan of the ebook reader in Calibre.
I had been failing to make Calibre work with Hook after reinstalling my OS. I’d completely forgotten about these two shortcuts despite commenting above!
It didn’t work for me after I’d put the shortcuts in, but when I checked the Calibre preferences again they hadn’t saved. I set them again and it now works.
(Note that you have to click ‘Done’ for each shortcut AND the ‘Apply’ button at the bottom.)
I would like to implement this. When I open Calibre preferences I don’t see Shortcuts so I don’t even know how to get started. I am using using the latest version of Calibre (but version number is not indicated) and Mac OS Monterey.
Sorry, I found Shortcuts in the Calbre Preferences menu – in plain sight, just missed seeing it before. I followed your instructions and it works perfectly as promised. Thank you!