diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2013-08-20 14:14:35 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2013-08-20 14:14:35 +1200 |
commit | 9f7c58d5e13c09191d321c0fde52546544db8e4f (patch) | |
tree | d0e954be7d7dd841eb184c8a9887a4ef0c69cc8e /bash/bashrc.d | |
parent | Better var names for subfile config sourcing (diff) | |
download | dotfiles-9f7c58d5e13c09191d321c0fde52546544db8e4f.tar.gz dotfiles-9f7c58d5e13c09191d321c0fde52546544db8e4f.zip |
Alias cd directly rather than via alias
Diffstat (limited to 'bash/bashrc.d')
-rw-r--r-- | bash/bashrc.d/cd.bash | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/bash/bashrc.d/cd.bash b/bash/bashrc.d/cd.bash index 1b52fc01..4f3d5f64 100644 --- a/bash/bashrc.d/cd.bash +++ b/bash/bashrc.d/cd.bash @@ -1,6 +1,6 @@ # If given two arguments to cd, replace the first with the second in $PWD, # emulating a Zsh function that I often find useful; preserves options too -__cd() { +cd() { local opt OPTERR OPTIND local -a opts while getopts elP opt; do @@ -18,5 +18,4 @@ __cd() { builtin cd "${opts[@]}" "$@" fi } -alias cd='__cd' |