« Update on trainings | Home | MBS Filemaker Plugin … »

Fix the Spotlight search on Mac for REAL Studio projects

With REAL Studio REAL Software changed a few IDs like the bundle ID and the document type IDs. And that changes breaks Spotlight indexing.

To fix that you can do the following:

Open REAL Studio with a right click on the application and choose "show package contents". Now open the Contents folder and locate the info.plist file. Edit this file in a text editor like BBEdit. You find something like this:
			<key>LSItemContentTypes</key>
			<array>
				<string>com.realsoftware.realbasic.project</string>
				<string>com.realsoftware.realbasic.window</string>
				<string>com.realsoftware.realbasic.class</string>
			</array>
and replace it with the following by adding 3 lines for realstudio:
			<key>LSItemContentTypes</key>
			<array>
				<string>com.realsoftware.realbasic.project</string>
				<string>com.realsoftware.realbasic.window</string>
				<string>com.realsoftware.realbasic.class</string>
				<string>com.realsoftware.realstudio.project</string>
				<string>com.realsoftware.realstudio.window</string>
				<string>com.realsoftware.realstudio.class</string>
			</array>
Next, you go down and duplicate the three dictioanries (dict tags) in the array for UTImportedTypeDeclarations below. Basicly you add this entries to the array:
		<dict>
			<key>UTTypeConformsTo</key>
			<array>
				<string>public.composite-content</string>
				<string>public.data</string>
			</array>
			<key>UTTypeDescription</key>
			<string>REALbasic Project</string>
			<key>UTTypeIdentifier</key>
			<string>com.realsoftware.realstudio.project</string>
			<key>UTTypeReferenceURL</key>
			<string>http://www.realsoftware.com/</string>
			<key>UTTypeTagSpecification</key>
			<dict>
				<key>com.apple.ostype</key>
				<array>
					<string>RbBF</string>
				</array>
				<key>public.filename-extension</key>
				<array>
					<string>rbp</string>
					<string>rbvcp</string>
				</array>
			</dict>
		</dict>
		<dict>
			<key>UTTypeConformsTo</key>
			<array>
				<string>public.composite-content</string>
				<string>public.data</string>
			</array>
			<key>UTTypeDescription</key>
			<string>REALbasic Class</string>
			<key>UTTypeIdentifier</key>
			<string>com.realsoftware.realstudio.class</string>
			<key>UTTypeReferenceURL</key>
			<string>http://www.realsoftware.com/</string>
			<key>UTTypeTagSpecification</key>
			<dict>
				<key>com.apple.ostype</key>
				<array>
					<string>CbCl</string>
				</array>
				<key>public.filename-extension</key>
				<array>
					<string>rbo</string>
					<string>rbbas</string>
				</array>
			</dict>
		</dict>
		<dict>
			<key>UTTypeConformsTo</key>
			<array>
				<string>public.composite-content</string>
				<string>public.data</string>
			</array>
			<key>UTTypeDescription</key>
			<string>REALbasic Window</string>
			<key>UTTypeIdentifier</key>
			<string>com.realsoftware.realstudio.window</string>
			<key>UTTypeReferenceURL</key>
			<string>http://www.realsoftware.com/</string>
			<key>UTTypeTagSpecification</key>
			<dict>
				<key>com.apple.ostype</key>
				<array>
					<string>CbVw</string>
				</array>
				<key>public.filename-extension</key>
				<array>
					<string>rbw</string>
					<string>rbfrm</string>
				</array>
			</dict>
		</dict>

Here a fixed importer: realbasic.mdimporter.zip If you copy this one to /Library/Spotlight and delete the Importers inside your REAL Studio copies, the system should use the fixed one.

Next you can use "mdimport -L" in the Terminal and see which importer is used.
Run something like "mdimport -r /Library/Spotlight/REALbasic.mdimporter" where you point to the importer and ask to reindex files. Or use "sudo mdutil -E /" to reindex a whole system disc.
10 05 10 - 15:59