###Using Text Tags to Your Advantage
###Quick Summary
- The Benefit of Tags
- How you can Use Text Tags in your content
- How to Use in Script documents
- How to Use in KM Macros
- Request: Use Author Text Tags in Your Macros
Author.@YourForumName
If you want to more easily find macros of interest, and enable others to find your macros, please read on.
While a few people don't care for tags, I'm a huge fan of them.
Why?
Because they enable quick and accurate searching across almost all boundaries.
I learned something new from my good friend Chris (@ccstone) (which I very often do) about tags: You can more easily find your script files (on your Mac) if you include text tags in the body of the script document, like Chris does:
--------------------------------------------------------------------------------
# Auth: Christopher Stone
# dCre: 2015/07/25 03:06
# dMod: 2015/07/25 03:19
# Appl: Keyboard Maestro & System Events
# Task: Set Focus to Group List
# Libs: None
# Osax: None
# Tags: @Applescript, @Script, @System_Events, @Keyboard_Maestro, @Focus, @Group_List
--------------------------------------------------------------------------------
This enables you to use Mac Spotlight and/or Finder Search to quickly find the script of interest:
###Spotlight Search of my entire Mac drive
Note that is has found these text tags in a variety of documents:
- Evernote notes
- AppleScript script files
- Outlook messages
Wow!
OR, if I want to limit the search to a folder (and its sub-folders), I can use Finder Search:
###Finder Search of Specific Folder
BTW, for those of you that use Script Debugger 6, use of text tags in the "Open Quickly" (powered by Spotlight) works very well.
So, effective immediately, I am including text tags in all of my script files.
But wait! There's more ...
What about Keyboard Maestro?
Guess what? A KM Editor search finds these same text tags in embedded Execute Script Actions!
For example, a search for the "@Focus" tag finds the Macro that includes Chris' script "Set Focus to Macro List":
###KM Editor Search
This means we can add text tags to the ReleaseNotes Comment to facilitate finding macros of interest. For example, I just added these tags to my latest macro:
"[KM] UPLOAD Macro to New or Existing Topic"
TAGS: @KM, @Macro, @Upload, @Forum, @Tool
How cool is that !?!?!?
But wait!!! There's still MORE . . .
A search that I often want/need to do is to find Macros written by a specific person, like @ccstone and @DanThomas. Unfortunately, KM Macros do NOT have an "Author" field, so there is no way I can accurately do this.
Then it occured to me that all of us have KM forum names that we reference with an "@" symbol.
So, maybe I could just search the KM Editor for, say, "@ccstone". Well, that sort of works, but has two major shortcomings:
- I sometimes refer to other KM forum members even if they did not author the macro
- Some macros authored by them have their normal name, but not their forum name, so they macro is not found
###Macro Author ID
So, I suggest this: If you write a Macro, put this special tag in the top Comment which is for ReleaseNotes or Attribution:
Author.@<YourForumName>
as in:
Author.@JMichaelTX
This enables a KM Editor search using this special author tag.
For example: Author.@DanThomas
Notice here I just typed "author.dan" and the macros were found.
Also notice that this macro was co-authored by Chris, so I have also included the tag Author.@ccstone
. This means I would find this Macro searching for either author tag.
There may be other, better, naming conventions for the KM Macro author tag, and I'm open to suggestions. I would just really like for us to develop a consensus, and then all follow that convention.
Even if the author does not include the author tag, you can always add it after you download the macro, which is what I have done for macros by @ccstone and @DanThomas.
I hope you will find this topic helpful, and please feel free to critique, and add and improve as you see fit.