mirror of
https://github.com/pyenv/pyenv.git
synced 2025-11-16 07:13:53 -05:00
Made ksh portability changes
Added specific message for ksh in identifying the proper shell
initialization file.
Changed rbenv functiond definition to be more portable.
Shell functions should be defined by using the function command or
using the parenthesis grammar, but using both is not portable:
rbenv() {... -or-
function rbenv { ...
This commit is contained in:
@@ -41,6 +41,9 @@ if [ -z "$print" ]; then
|
|||||||
zsh )
|
zsh )
|
||||||
profile='~/.zshrc'
|
profile='~/.zshrc'
|
||||||
;;
|
;;
|
||||||
|
ksh )
|
||||||
|
profile='~/.profile'
|
||||||
|
;;
|
||||||
* )
|
* )
|
||||||
profile='your profile'
|
profile='your profile'
|
||||||
;;
|
;;
|
||||||
@@ -71,7 +74,7 @@ echo 'rbenv rehash 2>/dev/null'
|
|||||||
commands=(`rbenv commands --sh`)
|
commands=(`rbenv commands --sh`)
|
||||||
IFS="|"
|
IFS="|"
|
||||||
cat <<EOS
|
cat <<EOS
|
||||||
function rbenv() {
|
function rbenv {
|
||||||
command="\$1"
|
command="\$1"
|
||||||
if [ "\$#" -gt 0 ]; then
|
if [ "\$#" -gt 0 ]; then
|
||||||
shift
|
shift
|
||||||
|
|||||||
Reference in New Issue
Block a user