Hi
When someone writes a keyword using a rule with Hazel, where does the keyword go?
Two things I am wondering:
1) Do you use MDItemSetAttribute to set the keywords in spotlight?
2) Do you set keywords in the file attributes (xattr)?
--Tom
Moderators: Mr_Noodle, Moderators
Mr_Noodle wrote:you should start migrating towards using the comments field instead as it's a better supported and more robust solution.
… it appears that the de facto convention for tagging files is to add them to the comments field.
I didn't mean to imply that, though Hazel only supports Leap's user-defined tags indirectly through Spotlight Comments. I'm not (and won't be) using those for file tagging even if Hazel's interaction is reliable and:Mr_Noodle wrote:Could you specify how Hazel does not work reliably with Leap tags?
Probably, though it's still just an informal solution. Part of the trouble is Spotlight Comments allow tags to be loosely defined, e.g. using different prefixes and/or delimiters.As far as using Spotlight comments for tags, it's the best solution there is right now.
Sure, which are sufficient reasons for some people.It is common to everyone and is accessible by users in Finder.
That's the only possibility I'm aware of now, too.The only other solution I can think of using using an xattr (extended attribute).
I'd love to see more developer ideas and consensus about alternatives to Spotlight Comments for tagging. It's a topic I'd surely bring up with folks I'd meet at WWDC, if I were fortunately enough to be attending.The problem with that is that you have to get all the devs to start using the same one.
Free format Spotlight Comments already have to be specially structured/treated to conform to any tagging pseudo-conventions, which has proven to be problematic (more often than I'm comfortable with).On top of that, users will not be able to see or change the tags without a special program.
So far nothing specific in mind beyond SpotMeta and some Ironic Support Forum discussions (e.g. here and here).If you have something else in mind, please share it but right now I'm not really sure where the problem is.
I agree with retiring that feature, with Spotlight Comments for tags as the currently preferred alternative (caveat emptor).I'm considering retiring the keywords feature in favor of having people use the comments field for tags.
Being aware of certain problems that can occur using Spotlight Comments for storing file tags is why I choose to avoid using (and recommending) them for that purpose. That doesn't make it terrible, just for some people (including me) those risks outweigh the benefits.Mr_Noodle wrote:I'm still not sure why tags in comments is such a terrible thing.
I realize things like that have motivated and can still favor using Spotlight Comments for tags.It is the result of users coming up with a system using the interfaces available to them. While having some specialized program to do it how you want it in particular may be "cleaner" to you, keep in mind that unless it ships with the system, it's not something you could rely on as being widespread or somewhat standardized.
If file tags are important to me they certainly can't be trusted to something that seems to work fine.I'm considering talking to other devs about it but it will require a lot of coordination amongst several devs for something that for the majority of people seems to work fine.
Based on what I've read MDItemSetAttribute is still private in 10.5 -- it's not in Apple Developer documentation.countach wrote:they are actually put into xattrs if you use MDItemSetAttribute
Yep, and easily applicable to the defacto ones for OS X file tagging.Mr_Noodle wrote:As they say, the great thing about standards is that there are so many to choose from.
Some software uses '@'-prefixed and comma-separated tags, sometimes as alternatives to &/Space. And I think some allows double-quoted multi-word tags, e.g. @"This is one tag".IIRC, I think it's keywords preceded by an ampersand and separated by spaces but maybe someone who uses other tagging software can elaborate.