prezto_config/modules/haskell/init.zsh

21 lines
501 B
Bash
Raw Normal View History

#
# Enables local Haskell package installation.
#
# Authors:
# Sebastian Wiesner <lunaryorn@googlemail.com>
#
2012-07-23 21:00:44 +02:00
# Return if requirements are not found.
if (( ! $+commands[ghc] )); then
return 1
fi
# Prepend Cabal per user directories to PATH/MANPATH.
if [[ "$OSTYPE" == darwin* && -d $HOME/Library/Haskell ]]; then
path=($HOME/Library/Haskell/bin(/N) $path)
manpath=($HOME/Library/Haskell/man(/N) $manpath)
else
path=($HOME/.cabal/bin(/N) $path)
2012-09-20 14:34:22 +02:00
manpath=($HOME/.cabal/man(/N) $manpath)
fi