MCPcopy Index your code
hub / github.com/deanishe/alfred-sublime-text

github.com/deanishe/alfred-sublime-text @v3.2.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release v3.2.0 ↗ · + Follow
85 symbols 189 edges 13 files 48 documented · 56% updated 3y agov3.3.0-beta2 · 2021-11-15★ 742 open issues
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Sublime Text Projects Alfred Workflow

View, filter and open your Sublime Text (or VSCode) project files.

Download & Installation


Download the workflow from GitHub and install by double-clicking the Sublime-Text-Projects-X.X.X.alfredworkflow file.

Catalina and later

If you're running Catalina or later (macOS 10.15+), you'll need to grant the workflow executable permission to run.

Usage


  • .st [<query>] — List/filter your .sublime-project files
    • — Open result in Sublime Text
    • ⌘+↩ — Reveal file in Finder
  • .st rescan — Reload cached list of projects
  • .st config — Show the current settings
    • Workflow Is Up To Date / Workflow Update Available — Install update or check for update
    • Edit Config File — Open workflow's config file in Sublime Text
    • View Help File — Open README in your browser
    • Report Issue — Open GitHub issue tracker in your browser
    • Visit Forum Thread — Open workflow's thread on alfredforum.com
    • Rescan Projects — Reload list of projects

You can enter the words search or config as a search query anywhere to jump to that screen.

How it works


The workflow scans your system for .sublime-project (or .code-workspace) files using locate, mdfind and (optionally) find. It then caches the list of projects for 10 minutes (by default).

As the locate database isn't enabled on most machines (and isn't updated frequently in any case), and mdfind ignores hidden directories, there is an additional, optional find-based scanner to "fill the gaps", which you must specifically configure (see below).

Configuration


Scan intervals are configured in the workflow's configuration sheet in Alfred Preferences:

Variable Usage
INTERVAL_FIND How long to cache find search results for
INTERVAL_LOCATE How long to cache locate search results for
INTERVAL_MDFIND How long to cache mdfind search results for
VSCODE Set to 1 or true to switch to Visual Studio Code mode

The interval values should be of the form 10m or 2h. Set to 0 to disable a particular scanner.

The workflow should work "out of the box", but if you have project files in directories that mdfind doesn't see (hidden directories, network shares), you may have to explicitly add some search paths to the sublime.toml configuration file in the workflow's data directory. The file is created on first run, and you can use .stconfig > Edit Config File to open it.

These directories are searched with find.

You can also add glob patterns to the excludes list in the settings file to ignore certain results. Excludes apply to all scanners.

The options are documented in the settings file itself.

Licensing, thanks


All the code is released under the MIT Licence.

The workflow is based on the AwGo workflow library, also released under the MIT Licence.

The icons are based on Font Awesome and Material Design Icons.

Extension points exported contracts — how you extend this code

Scanner (Interface)
Scanner finds Sublime Text project files. [3 implementers]
scan.go
Filterer (FuncType)
Filterer selectively passes through strings
filter.go

Core symbols most depended-on inside this repo

Use
called by 5
filter.go
Name
called by 4
scan.go
NewScanManager
called by 4
scan.go
cacheName
called by 4
scan.go
filterMatches
called by 4
scan.go
Scan
called by 3
scan.go
IsActive
called by 3
scan.go
Load
called by 3
scan.go

Shape

Function 53
Method 19
Struct 11
FuncType 1
Interface 1

Languages

Go100%

Modules by API surface

scan.go32 symbols
magefile.go12 symbols
cli.go11 symbols
project.go6 symbols
config.go5 symbols
project_test.go4 symbols
filter.go4 symbols
main.go3 symbols
util.go2 symbols
icons.go2 symbols
filter_test.go2 symbols
util_test.go1 symbols

For agents

$ claude mcp add alfred-sublime-text \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page