Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/chrissimpkins/glue
Glue is a plugin that joins your shell to Sublime Text in quasi-perfect harmony.
https://github.com/chrissimpkins/glue
Last synced: 8 days ago
JSON representation
Glue is a plugin that joins your shell to Sublime Text in quasi-perfect harmony.
- Host: GitHub
- URL: https://github.com/chrissimpkins/glue
- Owner: chrissimpkins
- License: mit
- Created: 2014-03-22T00:03:39.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2017-09-29T01:54:52.000Z (about 7 years ago)
- Last Synced: 2024-10-22T22:55:05.095Z (17 days ago)
- Language: Python
- Homepage: http://gluedocs.readthedocs.org/
- Size: 75.2 KB
- Stars: 253
- Watchers: 11
- Forks: 10
- Open Issues: 36
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- sublime-bookmarks - Glue - platform, extensible plug-in for Sublime Text 2 and 3 that connects your favorite editor to your shell. (Extensions / General Purpose)
README
No longer under active development.
===================================Glue
====[Glue](https://github.com/chrissimpkins/glue) is a cross-platform, [extensible](http://gluedocs.readthedocs.org/en/latest/extend-glue.html) plug-in for [Sublime Text 2 and 3](http://www.sublimetext.com/) that connects your favorite editor to your shell.
Detailed documentation is available on [http://gluedocs.readthedocs.org](http://gluedocs.readthedocs.org).
## Confirm Your PATH
Before you get started, please confirm your system PATH string in the Glue settings. [Here are the instructions](http://gluedocs.readthedocs.org/en/latest/install.html#confirm-your-path).
## Launch
#### Open with Right Click Menu
![Right Click Menu](http://gluedocs.readthedocs.org/en/latest/_images/popup-open-glue.png "Open Glue with the Right Click Menu")
#### Open with the Command Palette
![Command Palette](http://gluedocs.readthedocs.org/en/latest/_images/command-palette-open.png "Open Glue with Command Palette")
#### Open with Keybinding
```
Ctrl - Alt - G
```## Enter Commands
Use the command input box at the bottom of the screen to enter system commands just like you would in your terminal:
![Enter Commands in Glue](http://gluedocs.readthedocs.org/en/latest/_images/command-entry-example.png "Command Entry with Glue")
and the standard output is displayed in an editor view.
## System Utilities
It works with system utilities:
#### grep
![Grep Example](http://gluedocs.readthedocs.org/en/latest/_images/grep-example.png "Grep Example")
#### cURL
![cURL Example](http://gluedocs.readthedocs.org/en/latest/_images/curl-example.png "cURL Example")
## Scripting Languages
It works with scripting languages:
![Scripting Languages Examples](http://gluedocs.readthedocs.org/en/latest/_images/scripting-language-example.png "Scripting Languages Examples")
## Inter-Process Communication
Pipelining data between processes works. You get the standard output from the final executable in the sequence:
![Pipelining Example](http://gluedocs.readthedocs.org/en/latest/_images/pipelining-examples.png "Pipelining Example")
## Version Control
Version control tasks are accessible inside the editor:
![Version Control Example](http://gluedocs.readthedocs.org/en/latest/_images/git-example.png "Version Control Example")
## Compile, Unit Test, Profile, Minify, Compress...
You get the picture.
## Navigation & Working Directory State
Glue includes its own version of the `cd` command that allows you to navigate around your directory structure while maintaining your current working directory state between calls to the shell.
## File Management
Open files in the Sublime Text editor by file path:
```
█ glue open [filepath2] [...]
```or by wildcard pattern:
```
█ glue wco
```and create new files with:
```
█ glue new
```## Available Glue Commands
Glue includes its own set of commands to perform common tasks. You can extend these with aliases (see [information below](https://github.com/chrissimpkins/glue#extend-sublime-text-with-glue-extensions)).
Usage examples with available command arguments are in [the documentation](http://gluedocs.readthedocs.org/en/latest/commands.html).
CommandDescription
cdchange directory
exit
exit the Glue terminal
glue browse
open URL or local project file in default browser
glue clear
clear text in the Glue view
glue finder
reveal current directory (default) or optional path in finder
glue goto
Sublime Text GoTo Anything search
glue help
view help documentation in Glue view
glue localhost
open default web browser to local server
glue new
open a new Sublime Text buffer
glue open
open one or more project files by filepath
glue path
display the system PATH setting that is used by Glue
glue user
display alphabetized list of your Glue user extensions
glue wco
open one or more files by wildcard pattern
## Extend Sublime Text With Glue Extensions
You can build Sublime Text extensions **with your favorite language** or extend Sublime Text **with any system utility** using Glue command extensions. These are aliases for system commands that can be called from the Glue command line using the syntax:
```
█ glue [optional arguments]
```You have the option to pass additional command line arguments, clipboard data, or the current working directory path to the mapped system command with [template tags](http://gluedocs.readthedocs.org/en/latest/extend-glue.html#define-your-command-extensions).
### The Glue-Commands Directory
Create a directory in your Sublime Text `Packages` directory (`Preferences > Browse Packages`) that is named `Glue-Commands`.
### The glue.json File
Create a new file in this directory with the following path `Glue-Commands/glue.json`.
Use the `glue.json` file to create Glue extensions with `key = command name` to `value = command string` mapping.
### Example
You could make a command that executes a local image compression shell script on the path `/Users/me/scripts/cruncher.sh` with the following syntax:
``` json
{
"crunch": "/Users/me/scripts/cruncher.sh {{args}}"
}
```Then use it in Glue like this:
```
█ glue crunch image.png
```The mapped system command is executed as:
```
/Users/me/scripts/cruncher.sh image.png
```in your current working directory and is accessible in any Sublime Text project.
Make as many as you'd like. You can use the following command to reference an alphabetized list of your extensions:
```
█ glue user
```More detailed extension documentation (including additional examples) is [available here](http://gluedocs.readthedocs.org/en/latest/extend-glue.html).
## Changelog
The changelog is available [here](https://github.com/chrissimpkins/glue/releases).
## License
[MIT License](https://github.com/chrissimpkins/glue/blob/master/LICENSE)