Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #241 from djgoku/perlbrew_path_is_empty_fix

Fixed the order since -n returns true if non-zero
  • Loading branch information...
commit a6443450344b573d98ddcf7ef11202b65f792b33 2 parents 4af6e4e + 881655a
Kang-min Liu authored
Showing with 8 additions and 8 deletions.
  1. +4 −4 lib/App/perlbrew.pm
  2. +4 −4 perlbrew
8 lib/App/perlbrew.pm
View
@@ -1941,10 +1941,10 @@ __perlbrew_set_path () {
export PATH_WITHOUT_PERLBREW=` perl -e 'print join ":", grep { index($_, $ENV{PERLBREW_HOME}) < 0 } grep { index($_, $ENV{PERLBREW_ROOT}) < 0 } split/:/,$ENV{PATH};' `
- if [ -n "$PERLBREW_PATH" ]; then
- export PATH=${PERLBREW_PATH}/bin:${PATH_WITHOUT_PERLBREW}
- else
- export PATH=${PERLBREW_PATH}:${PATH_WITHOUT_PERLBREW}
+ if [ -n "$PERLBREW_PATH" ]; then
+ export PATH=${PERLBREW_PATH}:${PATH_WITHOUT_PERLBREW}
+ else
+ export PATH=${PERLBREW_ROOT}/bin:${PATH_WITHOUT_PERLBREW}
fi
hash -r
8 perlbrew
View
@@ -95,10 +95,10 @@ $fatpacked{"App/perlbrew.pm"} = <<'APP_PERLBREW';
export PATH_WITHOUT_PERLBREW=` perl -e 'print join ":", grep { index($_, $ENV{PERLBREW_HOME}) < 0 } grep { index($_, $ENV{PERLBREW_ROOT}) < 0 } split/:/,$ENV{PATH};' `
- if [ -n "$PERLBREW_PATH" ]; then
- export PATH=${PERLBREW_PATH}/bin:${PATH_WITHOUT_PERLBREW}
- else
- export PATH=${PERLBREW_PATH}:${PATH_WITHOUT_PERLBREW}
+ if [ -n "$PERLBREW_PATH" ]; then
+ export PATH=${PERLBREW_PATH}:${PATH_WITHOUT_PERLBREW}
+ else
+ export PATH=${PERLBREW_ROOT}/bin:${PATH_WITHOUT_PERLBREW}
fi
hash -r
Please sign in to comment.
Something went wrong with that request. Please try again.