116116function virtualenvwrapper_cd {
117117 if [ -n " ${ZSH_VERSION:- } " ]
118118 then
119- builtin \ c d -q " $@ "
119+ builtin cd -q " $@ "
120120 else
121- builtin \ c d " $@ "
121+ builtin cd " $@ "
122122 fi
123123}
124124
@@ -152,7 +152,7 @@ function virtualenvwrapper_derive_workon_home {
152152
153153 # If the path is relative, prefix it with $HOME
154154 # (note: for compatibility)
155- if echo " $workon_home_dir " | (unset GREP_OPTIONS; command \ g rep ' ^[^/~]' > /dev/null)
155+ if echo " $workon_home_dir " | (unset GREP_OPTIONS; command grep ' ^[^/~]' > /dev/null)
156156 then
157157 workon_home_dir=" $HOME /$WORKON_HOME "
158158 fi
@@ -161,7 +161,7 @@ function virtualenvwrapper_derive_workon_home {
161161 # path might contain stuff to expand.
162162 # (it might be possible to do this in shell, but I don't know a
163163 # cross-shell-safe way of doing it -wolever)
164- if echo " $workon_home_dir " | (unset GREP_OPTIONS; command \ g rep -E ' ([\$~]|//)' > /dev/null)
164+ if echo " $workon_home_dir " | (unset GREP_OPTIONS; command grep -E ' ([\$~]|//)' > /dev/null)
165165 then
166166 # This will normalize the path by:
167167 # - Removing extra slashes (e.g., when TMPDIR ends in a slash)
@@ -197,7 +197,7 @@ function virtualenvwrapper_verify_workon_home {
197197# Function to wrap mktemp so tests can replace it for error condition
198198# testing.
199199function virtualenvwrapper_mktemp {
200- command \ m ktemp " $@ "
200+ command mktemp " $@ "
201201}
202202
203203# Expects 1 argument, the suffix for the new file.
@@ -240,7 +240,7 @@ function virtualenvwrapper_run_hook {
240240 if [ ! -f " $hook_script " ]
241241 then
242242 echo " ERROR: virtualenvwrapper_run_hook could not find temporary file $hook_script " 1>&2
243- command \ r m -f " $hook_script "
243+ command rm -f " $hook_script "
244244 return 2
245245 fi
246246 # cat "$hook_script"
@@ -256,7 +256,7 @@ VIRTUALENVWRAPPER_PYTHON=$VIRTUALENVWRAPPER_PYTHON and that PATH is
256256set properly.
257257EOF
258258 fi
259- command \ r m -f " $hook_script "
259+ command rm -f " $hook_script "
260260 return $result
261261}
262262
@@ -322,7 +322,7 @@ function virtualenvwrapper_initialize {
322322
323323# Verify that the passed resource is in path and exists
324324function virtualenvwrapper_verify_resource {
325- typeset exe_path=" $( command \ w hich " $1 " | (unset GREP_OPTIONS; command \ g rep -v " not found" )) "
325+ typeset exe_path=" $( command which " $1 " | (unset GREP_OPTIONS; command grep -v " not found" )) "
326326 if [ " $exe_path " = " " ]
327327 then
328328 echo " ERROR: virtualenvwrapper could not find $1 in your path" >&2
@@ -553,7 +553,7 @@ function rmvirtualenv {
553553 virtualenvwrapper_cd " $WORKON_HOME "
554554
555555 virtualenvwrapper_run_hook " pre_rmvirtualenv" " $env_name "
556- command \ r m -rf " $env_dir "
556+ command rm -rf " $env_dir "
557557 virtualenvwrapper_run_hook " post_rmvirtualenv" " $env_name "
558558
559559 # If the directory we used to be in still exists, move back to it.
@@ -585,11 +585,11 @@ function virtualenvwrapper_show_workon_options {
585585 # 5. Eliminate any lines with * on them because that means there
586586 # were no envs.
587587 (virtualenvwrapper_cd " $WORKON_HOME " && echo * /$VIRTUALENVWRAPPER_ENV_BIN_DIR /activate) 2> /dev/null \
588- | command \ t r " \n" " " \
589- | command \ s ed " s|/$VIRTUALENVWRAPPER_ENV_BIN_DIR /activate |/|g" \
590- | command \ t r " /" " \n" \
591- | command \ s ed " /^[[:space:]]*$/d" \
592- | (unset GREP_OPTIONS; command \ g rep -E -v ' ^\*$' ) 2> /dev/null
588+ | command tr " \n" " " \
589+ | command sed " s|/$VIRTUALENVWRAPPER_ENV_BIN_DIR /activate |/|g" \
590+ | command tr " /" " \n" \
591+ | command sed " /^[[:space:]]*$/d" \
592+ | (unset GREP_OPTIONS; command grep -E -v ' ^\*$' ) 2> /dev/null
593593}
594594
595595function _lsvirtualenv_usage {
0 commit comments