diff options
author | gregstallings <gregstallings@gmail.com> | 2013-09-15 21:44:43 -0700 |
---|---|---|
committer | Mathias Bynens <mathias@qiwi.be> | 2013-09-21 16:21:16 +0200 |
commit | 3dc47ffd5559eddf7b1a5ce1e2085fa072ad817f (patch) | |
tree | e6b4bfc173204f64f64f0f49feda7b478be1094e | |
parent | c8a48ee28c70ab8ad6b3f960af33f8e498780b14 (diff) | |
download | dotfiles-3dc47ffd5559eddf7b1a5ce1e2085fa072ad817f.tar.gz dotfiles-3dc47ffd5559eddf7b1a5ce1e2085fa072ad817f.tar.bz2 dotfiles-3dc47ffd5559eddf7b1a5ce1e2085fa072ad817f.zip |
.functions: Add `m` to open stuff in TextMate
Closes #253.
-rw-r--r-- | .aliases | 1 | ||||
-rw-r--r-- | .functions | 10 |
2 files changed, 10 insertions, 1 deletions
@@ -15,7 +15,6 @@ alias g="git" alias h="history" alias j="jobs" alias v="vim" -alias m="mate ." alias s="subl ." alias o="open" alias oo="open ." @@ -251,3 +251,13 @@ function gi() { local IFS=, eval npm install --save-dev grunt-{"$*"} } + +# `m` with no arguments opens the current directory in TextMate, otherwise +# opens the given location +function m() { + if [ $# -eq 0 ]; then + mate . + else + mate "$@" + fi +} |