All Projects → deanishe → alfred-sublime-text

deanishe / alfred-sublime-text

Licence: MIT license
Filter and open your Sublime Text (2 and 3) project files from Alfred.

Programming Languages

go
31211 projects - #10 most used programming language
javascript
184084 projects - #8 most used programming language
shell
77523 projects

Projects that are alternatives of or similar to alfred-sublime-text

alfred-ask-create-share
Alfred workflow for creating web submissions (Stack Exchange, Forums and more)
Stars: ✭ 30 (-54.55%)
Mutual labels:  alfred, alfred-workflow, awgo
Projectmaker
A Sublime Text 2/3 plugin to allow creating any kind of project from your own custom templates
Stars: ✭ 233 (+253.03%)
Mutual labels:  sublime-text, project, sublime-text-3
alfred bluetooth controller
Alfred workflow for managing bluetooth settings and -connections
Stars: ✭ 63 (-4.55%)
Mutual labels:  alfred, alfred-workflow
alfred-night-shift
🌝 Alfred 3 workflow to toggle night shift
Stars: ✭ 18 (-72.73%)
Mutual labels:  alfred, alfred-workflow
bookends-tools
Alfred Workflow to Integrate with Bookends, an academic reference manager/bibliography tool for macOS
Stars: ✭ 78 (+18.18%)
Mutual labels:  alfred, alfred-workflow
alfred-qiita-workflow
Qiita on Alfred
Stars: ✭ 57 (-13.64%)
Mutual labels:  alfred, alfred-workflow
i-sheet-you-not
Automagically turn Excel spreadsheets into Alfred 3 Workflows
Stars: ✭ 67 (+1.52%)
Mutual labels:  alfred, alfred-workflow
alfred
A fast, simple way to make Alfred workflow script filters in Go
Stars: ✭ 25 (-62.12%)
Mutual labels:  alfred, alfred-workflow
alfred-http-status-codes
Alfred Workflow to search for http status code meanings
Stars: ✭ 30 (-54.55%)
Mutual labels:  alfred, alfred-workflow
alfred-urban-dictionary
Search Urban Dictionary from Alfred.
Stars: ✭ 53 (-19.7%)
Mutual labels:  alfred, alfred-workflow
FileHistory
Sublime Text plugin that keeps track of files which have been recently closed, as well as files that have been recently accessed.
Stars: ✭ 51 (-22.73%)
Mutual labels:  sublime-text, sublime-text-3
alfred-hugo
Alfred workflow bindings for NodeJS
Stars: ✭ 17 (-74.24%)
Mutual labels:  alfred, alfred-workflow
Sublime-Pretty-Shell
🐚 Shell Script Formatter / Syntax Checker (Powered by shfmt)
Stars: ✭ 28 (-57.58%)
Mutual labels:  sublime-text, sublime-text-3
Golite
Add essential language support for the Go language to Sublime Text 3.
Stars: ✭ 14 (-78.79%)
Mutual labels:  sublime-text, sublime-text-3
alfred-last2imgur
Alfred workflow to upload the last screenshot taken to Imgur + (delete and minify image)
Stars: ✭ 15 (-77.27%)
Mutual labels:  alfred, alfred-workflow
alfred-passwords-workflow
An Alfred 4 workflow that allows you to quickly generate strong passwords.
Stars: ✭ 42 (-36.36%)
Mutual labels:  alfred, alfred-workflow
alfred-jira-search
Alfred Workflow to quickly search through Jira issues 🔎
Stars: ✭ 23 (-65.15%)
Mutual labels:  alfred, alfred-workflow
alfred-string-operations
Perform string operations to clipboard content
Stars: ✭ 70 (+6.06%)
Mutual labels:  alfred, alfred-workflow
alfred-jira-search
An Alfred workflow to search for Jira tickets
Stars: ✭ 26 (-60.61%)
Mutual labels:  alfred, alfred-workflow
sublime-meetio-theme
The most powerful and adaptive theme for Sublime Text 3
Stars: ✭ 71 (+7.58%)
Mutual labels:  sublime-text, sublime-text-3

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

There is one keyword, .st, which works as follows:

  • .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
    • Rescan Projects — Reload list of projects
    • Edit Config File — Open workflow's configuration file
    • Editor: Sublime Text / Editor: VS Code — Which editor is selected
    • Action Project File — Whether copying/actioning a search result should use the path of the project file instead of that of the first project directory
    • 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

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

Universal Actions

There are Universal Actions for files, URLs and text. Files are opened, and text is inserted into a new document.

Multiple URLs are treated as text, but a single URL is retrieved with curl and a new document is created with its contents.

Hotkeys

The workflow has two Hotkeys (marked red) that you can set to open the currently-selected files in any application in Sublime Text. One Hotkey is for Finder and Path Finder only, and the other is for all other applications. You should set them to the same keyboard shortcut.

The Finder/Path Finder variant doesn't rely on Alfred's "Selection in macOS" feature, and will open the frontmost window's target (the folder whose contents it's showing) if nothing is selected.

External Triggers

The workflow has the following External Triggers that can be used from scripts or other workflows:

Name Description
new Create a new document containing the given text
open Open the specified path in Sublime Text
open-url Create a new document with the data retrieved from URL
search Show project search results for given query

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).

NOTE: When the workflow is asked to open a directory (e.g. via External Trigger or Universal Action), it looks for a project file in the directory, and opens that instead if one is found.

Configuration

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

Variable Type Usage
INTERVAL_FIND duration How long to cache find search results for
INTERVAL_LOCATE duration How long to cache locate search results for
INTERVAL_MDFIND duration How long to cache mdfind search results for
ACTION_PROJECT_FILE boolean Copying/actioning a search result uses project file path
VSCODE boolean Switch to Visual Studio Code mode

duration values should be of the form 10m or 2h. Set to 0 to disable a particular scanner. boolean values should be of the form true and false or 1 and 0.

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 .st config > Workflow Settings > 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.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].