Big fan of Hookmark, especially for linking to Apple’s Mail.app !
But, when linking to a given email in Mail - it pulls the email up as an independent document, which lacks the context of the thread the email is apart of. This threading of the email can be seen elsewhere in the Mail interface. Example photo of said threading:
I assume there isn’t a way to change this behavior, either in Hookmark or in Mail. So, does anyone a macOS desktop mail application, which is Hookmark compatible, but when those Hookmark links are resolved, also opens to a GUI view where the thread is associated with the email is viewable/browsable?
(Cloud / web interface versions of mail applications, also applicable, if they have this thread interaction with hookmark)
I use Hookmark with MailMate, and there again invoking a linked message brings up the message in isolation. MM has buttons to show messages in same conversation (and same correspondents), but these are greyed when the message is shown in a separate window. Maybe a feature request for the dev of MM unless there is a way to adapt the Hookmark script to call the link in context in MM?
In Apple Mail, if the email opens into a separate window, right click on the opened email toolbar, choose “Customize Toolbar…” and drag “Show/Hide Related Messages” into the toolbar. Then when you follow the Hookmark link and that single email opens, click the “Show/Hide Related Message” and the thread will open.
Edited to add more info: Once you add the button in the toolbar it will be there for all subsequent messages as well. So a one time customization.
Edited for clarity, “header” changed to “toolbar.”
Thanks @rwread ! That’s a great tip, and worked perfectly for me. Photos of the toolbar customization process below as a resource for folks that might find this thread:
@stevelw , I don’t know which command you mean. I didn’t see any Show/Hide Related Messages in the menubar (i.e. as a hotkeyed text command), like it is in the toolbar (as a button). CC @LucB as Dev to see if he has input
Here is the new “Open Item” script for Mail (No Preference setting yet).
You can replace the current “Open Item” script for Mail with the following script and see if it does the work.
Thank you
Summary
set MessageID to "$0"
set MessageID to text 9 thru -1 of MessageID
set MessageID to encodeText(MessageID, true, false)
tell application "Mail"
activate
try
set myurl to "open -a Mail \"message:%3c" & MessageID & "%3e\""
do shell script myurl
on error eStr number eNum
display dialog eStr & " Number: " & eNum buttons {"OK"} default button 1
return
end try
end tell
tell application "System Events"
tell process "Mail"
delay 0.5
try
click menu item "Show Related Messages" of menu 1 of menu bar item "View" of menu bar 1
on error
try
delay 1
click menu item "Show Related Messages" of menu 1 of menu bar item "View" of menu bar 1
end try
end try
end tell
end tell
on encodeText(theText, encodeCommonSpecialCharacters, encodeExtendedSpecialCharacters)
set theStandardCharacters to "abcdefghijklmnopqrstuvwxyz0123456789%"
set theCommonSpecialCharacterList to "$+!'/?;&@=#%><{}\"~`^\\|*"
set theExtendedSpecialCharacterList to ".-_:"
set theAcceptableCharacters to theStandardCharacters
if encodeCommonSpecialCharacters is false then set theAcceptableCharacters to theAcceptableCharacters & theCommonSpecialCharacterList
if encodeExtendedSpecialCharacters is false then set theAcceptableCharacters to theAcceptableCharacters & theExtendedSpecialCharacterList
set theEncodedText to ""
repeat with theCurrentCharacter in theText
if theCurrentCharacter is in theAcceptableCharacters then
set theEncodedText to (theEncodedText & theCurrentCharacter)
else
set theEncodedText to (theEncodedText & encodeCharacter(theCurrentCharacter)) as string
end if
end repeat
return theEncodedText
end encodeText
on encodeCharacter(theCharacter)
set theASCIINumber to (the ASCII number theCharacter)
set theHexList to {"0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "A", "B", "C", "D", "E", "F"}
set theFirstItem to item ((theASCIINumber div 16) + 1) of theHexList
set theSecondItem to item ((theASCIINumber mod 16) + 1) of theHexList
return ("%" & theFirstItem & theSecondItem) as string
end encodeCharacter