Giter VIP home page Giter VIP logo

shell-turtlestein's Introduction

Shell Turtlestein

A quick and simple way to run arbitrary shell commands in Sublime Text 2.

Mr. Turtlestein acts as a more flexible alternative to Sublime's build systems. Commands run in your project's directory:

input a shell command

And display their output just like Sublime's build systems:

command output

To pipe the current file or selections to the command, prepend a pipe character (i.e. |) to the command. To redirect a command's output to the view append an angle bracket (i.e. >) to the command. For example, | sort > will sort the active file or its selected lines.

Snippets are available for frequently used commands. All snippets with the scope name source.shell (source.dosbatch for Windows users) can be used in the prompt shown above. I have some examples you can take a look at to get an idea for this.

Default keybindings

  • Ctrl + Shift + C (Cmd + Shift + C): prompt for a shell command
  • Ctrl + Alt + Shift + C (Cmd + Alt + Shift + C): launch a terminal in the window's directory

Optional Configuration

In your own Packages/User/Shell Turtlestein.sublime-settings file you can override the following settings:

  • surround_cmd: A two-element array that specifies text to append before and after the command (e.g. ["source ~/.profile && ", ""]).
  • exec_args: The arguments that will be passed to ExecCommand. The same options that are available to build systems are available here, but file_regex, line_regex, encoding, env, and path are the only options that make sense to use with this plugin. Arguments specified in the cmd_settings (see below) will override these defaults.
  • cmd_settings: An array of configurations to use for commands that are executed. The first configuration to match the command being run will be used. The keys that each configuration should have are:
    • cmd_regex: A regex that must match the command for this configuration for this configuration to be used.
    • exec_args and surround_cmd override the settings described above for any matching command.

PAQ

Q: Who the balls is Shell Turtlestein?

A: He was a pet turtle that died in some episode of Modern Family. That's about as high-brow as my references get. R.I.P. Shell :(

Q: What does "PAQ" stand for?

A: Possibly asked questions

shell-turtlestein's People

Contributors

misfo avatar inkytonik avatar cj avatar

Watchers

Michael Updegraff avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.