Created
August 25, 2012 02:31
-
-
Save czi/3459051 to your computer and use it in GitHub Desktop.
perlbrew bashrc centos manpath fix (-q not valid)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
*** bashrc.orig 2012-08-24 21:19:36.492160130 -0500 | |
--- bashrc 2012-08-24 21:28:29.826663945 -0500 | |
*************** | |
*** 16,22 **** | |
--- 16,28 ---- | |
} | |
__perlbrew_set_path () { | |
+ if [[ -f /etc/centos-release ]] || [[ $(grep CentOS /etc/redhat-release) ]]; | |
+ then | |
+ export MANPATH_WITHOUT_PERLBREW=`perl -e 'print join ":", grep { index($_, $ENV{PERLBREW_ROOT}) } split/:/,qx(manpath);'` | |
+ else | |
export MANPATH_WITHOUT_PERLBREW=`perl -e 'print join ":", grep { index($_, $ENV{PERLBREW_ROOT}) } split/:/,qx(manpath -q);'` | |
+ fi | |
+ | |
if [ -n "$PERLBREW_MANPATH" ]; then | |
export MANPATH="$PERLBREW_MANPATH:$MANPATH_WITHOUT_PERLBREW" | |
else |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment