Home Download Buy Blog Forum Support

Enabling 'Goto Anything' in custom packages eg powershell

Enabling 'Goto Anything' in custom packages eg powershell

Postby SteveCooperOrg on Fri Feb 04, 2011 11:45 am

If you want to enable 'Goto Anything' in Sublime Text 2 for custom languages, it's fairly easy. You need to add a file called 'Symbol List.tmPreferences' to the package. This needs to be configured to contain the scopes you want to see in the symbol list. Here's the Symbol List.tmPreferences file for python;

Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
   <string>Symbol List</string>
   <!-- CHANGE HERE -->
   <string>source.python meta.function.python, source.python meta.class.python</string>

Note the list of scopes. For you own language, just change this.

I've updated the powershell package in the community packages repo, and you can now do '.ps1@my-function' to select function definitions in powershell files.
Maybe what you're looking for is at the http://www.sublimetextwiki.com
Posts: 193
Joined: Thu Mar 20, 2008 9:53 am

Return to Plugin Announcements

Who is online

Users browsing this forum: No registered users and 13 guests