On Thursday 27 May 2010 08:46:04, Magicloud Magiclouds wrote:
> I only have one alex installed under ~/.cabal/bin.
> It seems working with shell environment, but not cabal.
>

My guess:

You added ~/.cabal/bin to the path, but have quoted the path, like

export PATH="~/.cabal/bin:$PATH"

in your .bashrc

That does not work. Tilde expansion is *not* done for quoted strings, so 
cabal looks (among other places) for "~/.cabal/bin/alex". Now, there is no 
directory "~" in your file system, so alex is not found.

Check:
$ printenv PATH

If the output contains ~, it won't work. If it doesn't, well then something 
else must be broken.

Fixes
1) don't quote the path,
export PATH=~/.cabal/bin:$PATH
works.
2) (better) Use $HOME instead of ~ (works quoted or unquoted)
3) write out your home directory completely
_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to