Page 1 of 1

How to use Received Transport in conditions?

PostPosted: Thu Jul 28, 2022 3:32 am
by spaceship
How do I make a rule match when kMDItemUserSharedReceivedTransport includes com.apple.AirDrop?

I regularly export OPML files from a podcast player app on iPhone, which opens a share sheet where the quickest way to get them to the Mac is AirDrop. Because the filename is very common, I want to make sure Hazel only works on those.

Re: Hot to use Received Transport in conditions?

PostPosted: Thu Jul 28, 2022 9:24 am
by Mr_Noodle
Do "Get Info" on the file and check the metadata there to see if it is accessible.

Re: Hot to use Received Transport in conditions?

PostPosted: Thu Jul 28, 2022 4:15 pm
by spaceship
Mr_Noodle wrote:Do "Get Info" on the file and check the metadata there to see if it is accessible.


You mean in Finder? It doesn't show this data.

My current solution is "Passes shell script" with
Code: Select all
mdls -name kMDItemUserSharedReceivedTransport $1 | grep com.apple.AirDrop

Re: How to use Received Transport in conditions?

PostPosted: Fri Jul 29, 2022 8:27 am
by Mr_Noodle
That is probably the way to go then if it isn't visible there.

Re: How to use Received Transport in conditions?

PostPosted: Fri Jul 29, 2022 5:24 pm
by spaceship
Thanks