Skip to content

deanishe/alfred-subdir-search

Repository files navigation

Subdirectory Search (Alfred 2 Workflow)

Fuzzy search across the subtree of the specified root directory.

This Workflow has been replaced

Have a look at this one, instead. It's much better.

Note: This Workflow requires you to configure your own Script Filters in Alfred (by default, there is one configured for ~/Documents with keyword docs). See Configuration for instructions.

Download

Get the Workflow from GitHub.

What it does

This Workflow provides partial matching of path components, allowing you to drill down into your filesystem with a space-separated query. Each "word" of the query will be matched against the components of a directory or file's path, so a three-word query will only match at least three levels down from the specified root directory.

For example, I have a Script Filter set up to search ~/Code with keyword code:

python search.py ~/Code "{query}"

Entering code workflow into Alfred produces a list of all subdirectories somewhere under ~/Code whose names contain workflow (the search is case-insensitive):

Entering code alfred workflow produces a list of all subdirectories somewhere under ~/Code whose names contain workflow, which are also somewhere under a directory whose name contains alfred:

Configuration

The Workflow is pre-configured to search ~/Documents using the keyword docs. To search other directories, you'll have to add your own Script Filter(s), adjusting the Keyword and root directory in the Script field.

You can pass the -f or --files option to search.py to also search files.

Note: Searching files as well as directories makes the Workflow a lot slower.

Screenshots

Licence

This Workflow is released under the MIT Licence.

About

Alfred 2 Workflow to search subdirectories

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages