OSX - Spotlight indexing Rev Stacks

Jim Ault JimAultWins at yahoo.com
Thu Feb 12 14:23:19 EST 2009


This is very good info, Bernard, and I did not know about the mdimport tool.

Of course, the system Spotlight functionality would have to be 'shown' how
to get the field text from a Revolution stack, thus the need for a
'Revolution.mdimporter' definition file or stack reader file (I am not sure
what needs to be done here).

What might be easier is to make a tool (just like the recent Garzia
documentation thread) that generates a simple text file with all the
pertinent info {stack name, properties, card fields, ...} and saves this
data as a text file in a specific location (like RevSpotlightData folder).

The stack exporter tool has the UI that allows the user to save the info
desired, and process updates to the text file after the data stack is
modified or updated.

Part of the process for me is to have a Rev stack collect info about web
sites I am designing from both my development environ locally and on the web
ftp site, then export this to text files that become part of the Spotlight
database.

I will probably start building this tool next week.  This would be better
than an (mdimporter), since I would have control over exact formatting and
indexing of the data.  Of course, script containers could be done as a
separate text files and these would become Spotlight-indexed as well.

This leads to a saved-Spotlight-search on the folder
"RevSciptsIhaveKnownAndLoved"
"MyWebPhpCssJs"
"HtmlTagsWithClass=Animation"

Actually, the following works right now on my hard drive with scripts as
text files:
"--6.22.06" yields a list of stack scripts I documented as text files two
years ago with comments.
"on sendCurl "
"on preopenstack"
"altuit"
"on gotPacket"

One interesting check box in the "Search Other" list is
"The names of all the substacks in the stack"
just below "The text content of this item"

I am curious to know what "Spotlight items" Rev publishes.

The power for me is that this will allow me to connect my
web folders-local folders-Evernote-scripts-php-css-xls-javascript
+ photoshop layer names (obviously I will now use layer names better to tag
my psd's)
by using unique search tags


Thanks for triggering my thoughts and being able to see a way to tie lots of
documentation into connected threads (without Spotlight comments)

Jim Ault
Las Vegas

On 2/12/09 1:24 AM, "Bernard Devlin" <bdrunrev at gmail.com> wrote:

> Hi Jim
> I seem to remember some years ago that one of the updates to Rev was that
> stacks would become indexable by Spotlight.  Maybe that only related to the
> script of the stack rather than the stack's contents.
> 
> I don't use Spotlight much at all, but having a look around there seems to
> be the mdimport tool.  The Man page for this says it has these options:
> 
>      -f          Force mdimport to scan the files, bypassing path filtering
>                  rules.
> 
>      -r          Ask the server to reimport files for UTIs claimed by the
>                  listed plugin.  For example, the following would cause all
> of
>                  the chat files on the system to be reimported:
> 
>                        mdimport -r /System/Library/Spotlight/Chat.mdimporter
> 
> That looks like one can manually add files to the Spotlight index.  However,
> it looks like one might need a specific plugin like 'Chat.mdimporter'.
>  These are OS X bundles that contain an executable in their core.  The one I
> looked at (vCard.mdimporter) appears to be written in Obj C.
> 
> However, it looks to me like the plugin needs to meet the specifications set
> out in this document:
> http://developer.apple.com/DOCUMENTATION/Carbon/Conceptual/MDImporters/MDImpor
> ters.html#//apple_ref/doc/uid/TP40001279
> 
> The plugin bundle core needs to be executable. Maybe one could write a Rev
> application and bundle it up and the indexing program would call it?  For
> example, it appears here that someone wrote a specific importer in Python:
> http://www.jajsoft.com/category/python .
> 
> I expect you know this much already.
> 
> Bernard
> 
> On Wed, Feb 11, 2009 at 8:19 PM, Jim Ault <JimAultWins at yahoo.com> wrote:
> 
>> Is there a way of allowing/forcing the indexing of a stack containing
>> field data?
>> custom properties?
>> 
>> This would make the content searchable using the built-in OSX Spotlight
>> option ŒContents¹
>> 
>> Indexing occurs for programs that are ŒSpotlight-friendly¹, such as Adobe
>> PDF¹s
>> 
>> Of course, setting the Spotlight comments of the stack file would work, but
>> is very limited compared to a stack that contains data such as code,
>> project
>> notes, and demo stacks with notes, such as So Smart Tutorials.
>> 
>> Jim Ault
>> Las Vegas





More information about the use-livecode mailing list