[TxMt] running mysql on current file

Lang Riley lang at langriley.com
Tue Dec 21 21:49:57 UTC 2004

Sometimes you want to execute the SQL contained in the current file via:

Before running command: Do nothing
Command:  [your path to mysql if not in bash's path environment 
variable]/mysql -u[your username here] -p[your password here] < 
Standard Input: None (because $TM_FILEPATH is specified above; you 
could use just selected text too with $TM_SELECTED_TEXT)
Standard Output: Show in separate window

If you have line numbers showing in the gutter you can quickly find any 
syntax errors that mysql returns.

Simple. Useful.

More information about the textmate mailing list