diff --git a/shell/cd.sh b/shell/cd.sh index 929866e..eb43f73 100755 --- a/shell/cd.sh +++ b/shell/cd.sh @@ -1,13 +1,13 @@ #!/bin/sh #correct some fast tipped cds -function c { - if [ $1 == "d.." ]; then +c() { + if [ "$1" == "d.." ]; then cd ..; pwd; fi - if [ -d $1 ]; then - cd $1; + if [ -d "$1" ]; then + cd "$1"; pwd; fi return 0;