Cain Manor

Your Guide To All Things Cain™

Setup OS-X to quicklook vbs files

I have some .vbs files I wrote, and I thought that I should be able to quick­look them just like any other text file. Find­ing out exactly how wasn’t ter­ri­bly easy.

I use Tex­tWran­gler for all my lim­ited cod­ing needs. You should (empha­sis on should) be able to do this for any other edi­tor you want. This is what I had to do.

Edit /Applications/TextWrangler.app/Contents/Info.plist. Towards the top you’ll see a bunch of file exten­sions. I added vbs to the list.

<string>text</string>
<string>txt</string>
<string>vbs</string>
<string>wml</string>
<string>WML</string>

In the same file, but before the very last</dict>
</plist>
Add

<key>UTExportedTypeDeclarations</key>
<array>
<dict>
<key>UTTypeConformsTo</key>
<array>
<string>public.text</string>
<string>public.plain-text</string>
</array>
<key>UTTypeDescription</key>
<string>Microsoft Visual Basic</string>
<key>UTTypeIdentifier</key>
<string>com.macromates.textmate</string>
<key>UTTypeTagSpecification</key>
<dict>
<key>com.apple.ostype</key>
<string>TEXT</string>
<key>public.filename-extension</key>
<array>
<string>vbs</string>
</array>
</dict>
</dict>
</array>

And then

touch /Applications/TextWrangler.app

Comments are closed.