ctrl+shift+p filters: :st2 :st3 :win :osx :linux
Browse

Terminal

by Will Bond (wbond) ST2/ST3 Top 100

Launch terminals from the current file or the root project folder

Labels terminal

Details

Installs

  • Total 193K
  • Win 82K
  • OS X 62K
  • Linux 49K
Feb 8 Feb 7 Feb 6 Feb 5 Feb 4 Feb 3 Feb 2 Feb 1 Jan 31 Jan 30 Jan 29 Jan 28 Jan 27 Jan 26 Jan 25 Jan 24 Jan 23 Jan 22 Jan 21 Jan 20 Jan 19 Jan 18 Jan 17 Jan 16 Jan 15 Jan 14 Jan 13 Jan 12 Jan 11 Jan 10 Jan 9 Jan 8 Jan 7 Jan 6 Jan 5 Jan 4 Jan 3 Jan 2 Jan 1 Dec 31 Dec 30 Dec 29 Dec 28 Dec 27 Dec 26 Dec 25
Windows 9 88 101 148 150 175 156 176 118 126 184 174 190 188 174 113 143 181 183 198 186 208 125 140 178 188 189 209 202 126 113 176 168 190 202 185 26 35 65 112 153 201 201 102 129 119
OS X 4 53 75 84 97 96 101 100 75 64 93 103 117 98 94 51 63 94 105 111 108 120 69 76 116 100 121 109 87 70 72 111 87 109 116 92 25 14 28 53 95 93 101 58 78 76
Linux 6 73 54 65 81 82 87 73 74 43 73 61 88 84 72 62 54 70 86 76 68 82 53 59 85 81 81 82 70 57 59 77 76 86 77 81 25 13 30 51 60 57 76 38 45 39

Readme

Source
raw.​githubusercontent.​com

Sublime Terminal

Shortcuts and menu entries for opening a terminal at the current file, or the current root project folder in Sublime Text.

Features

  • Opens a terminal in the folder containing the currently edited file
  • Opens a terminal in the project folder containing the currently edited file

Installation

Download Package Control and use the Package Control: Install Package command from the command palette. Using Package Control ensures Terminal will stay up to date automatically.

Usage

  • Open Terminal at File Press ctrl+shift+t on Windows and Linux, or cmd+shift+t on OS X
  • Open Terminal at Project Folder Press ctrl+alt+shift+t on Windows and Linux, or cmd+alt+shift+t on OS X

In addition to the key bindings, terminals can also be opened via the editor context menu and the sidebar context menus.

Package Settings

The default settings can be viewed by accessing the Preferences > Package Settings > Terminal > Settings – Default menu entry. To ensure settings are not lost when the package is upgraded, make sure all edits are saved to Settings – User.

  • terminal
    • The terminal to execute, will default to the OS default if blank. OS X users may enter iTerm.sh to launch iTerm if installed.
    • Default: “”
  • parameters
    • The parameters to pass to the terminal. These parameters will be used if no custom parameters are passed via a key binding.
    • Default: []

Examples

Here are some example setups:

Cmder on Windows

{
  // Replace with your own path to cmder.exe
  "terminal": "C:\\Program Files\\cmder_mini\\cmder.exe",
  "parameters": ["/START", "%CWD%"]
}

xterm on GNU/Linux

{
  "terminal": "xterm"
}

iTerm on OS X

{
  "terminal": "iTerm.sh"
}

iTerm on OS X with tabs

{
  "terminal": "iTerm.sh",
  "parameters": ["--open-in-tab"]
}

Custom Parameters

With the parameters argument to the open_terminal and open_terminal_project_folder commands, it is possible to construct custom terminal environments.

The following is an example of passing the parameters -T 'Custom Window Title' to a terminal. Please note that this example is just an example, and is tailored to the XFCE terminal application. Your terminal may use the -T option for some other features or setting. Custom key bindings such as this would be added to the file opened when accessing the Preferences > Key Bindings – User menu entry (the file name varies by operating system).

{
  "keys": ["ctrl+alt+t"],
  "command": "open_terminal",
  "args": {
    "parameters": ["-T", "Custom Window Title"]
  }
}

A parameter may also contain the %CWD% placeholder, which will be substituted with the current working directory the terminal was opened to.

{
  "keys": ["ctrl+alt+t"],
  "command": "open_terminal",
  "args": {
    "parameters": ["-T", "Working in directory %CWD%"]
  }
}