Growing Commands
Runny lets you create new commands for things such as programs, opening urls, starting emails to people and saving textclips all by using the ‘new‘ command.
- new
Open the runny folder so shortcuts can be pasted. - new url [name] [url]
Creates a new url command which opens a website. Can contain special parameters. - new email [name] [email-address,...]
Creates a new email command which starts an email to a recipient. Can contain special parameters. - new cliptext [name] [text]
Creates a new cliptext command which sends a series of keys to the computer. Can contain special parameters.Text clips can also be created using the same parameter placeholders as above. In addition to parameters, you can invoke special keys using the syntax listed on Microsoft’s Developers Network.
- new script [name] [jscript]
Will create a mini-script using jscript. - new macro [name] [semi-colon delimited runny commands]
This will create a command which will execute many runny commands in a row. You can also include parameters and place holders. - new rex [name] [space delimited regexps]
Creates a command which applies one or more regular expressions to textual content in the clipboard.
Special Parameters
You can parameterise custom commands for urls and text clips using a {$1},{$2},etc notation. For example, to create a command ‘php‘ to lookup PHP commands type:
new php http://us2.php.net/manual-lookup.php?pattern={$1}&lang=en
Now when you type ‘php [anycommand]‘ it will replace {$1} in the url with [anycommand]. Each parameter separated by a space is referenced using {$1} in order of its command usage.
{$0} is a special entity that references all the passed parameters, spaces and all.
new g http://www.google.com/search?hl=en&q={$0}
The above command will create a custom command to search Google by typing ‘g search terms here‘
Parameters can be made to fall back on clipboard contents {clip} or user input {prompt Your Query} using a pipe to specify the fall backs.
new g http://www.google.com/search?hl=en&q={$0|clip|prompt Search Term}
This will look for a parameter passed via the run window first and if blank will attempt to use text in the clipboard. Finally if the clipboard doesn’t contain text data it will outright prompt the user for input.
General Commands
- math [math expression]
performs a simple math expression and alerts the answer or an error. Uses JScript syntax. - runny help
Opens a help dialog with a list of available commands - tweet [message]
sends a message to your twitter account. (requires twitter.com account) message - optional message to post to your twitter account, if left blank and a url is in the clipboard will prompt for a message and auto-include the url.
Clipboard Commands
Runny comes with some clipboard management commands that can be useful at times. Runny only supports text in the clipboard.
- push [key]
push the contents of the clipboard into a clipstack (numbered text file) for later retrieval or save it as a named clipboard by specifying a key. - pop [key]
pop the top item off the clipstack into the clipboard or push a named item into the clipboard. - dip [key]
similar to pop but will not remove the item from the stack. - shift
take the first pushed clipboard item from the bottom - merge
take the whole stack of clipboard items, merge them and place into clipboard - clear
erase the clipboard stack including any named clipboards.