> env PATH="/Users/me/gsoc2009/ghc-6.10.3-inst/bin:$PATH" which ghc env: which: No such file or directory
# My confusion went on for a while, edited slightly for concision. #what if which is just a builtin: nope: > env PATH="/Users/me/gsoc2009/ghc-6.10.3-inst/bin:$PATH" bash -c 'which ghc' env: bash: No such file or directory # did that again. # tried /usr/bin/bash : wrong location. #what if I *make* if find bash: not good enough: > env PATH="/Users/me/gsoc2009/ghc-6.10.3-inst/bin:$PATH" /bin/bash -c 'which ghc' /bin/bash: which: command not found #does which exist: well yes: > which which /usr/bin/which # forgot the -c once. #so what PATH is it really? and *why* do I need such a convoluted command just to find out: > env PATH="/Users/me/gsoc2009/ghc-6.10.3-inst/bin:$PATH" /bin/bash -c '/bin/echo $PATH' /Users/me/gsoc2009/ghc-6.10.3-inst/bin:/Users/me/scripts /Users/me/HOME/.cabal/bin /usr/local/sbin /usr/local/bin /usr/sbin /usr/bin /sbin /bin /usr/games /usr/X11R6/bin m...@east /U/m/g/ghc-6.10.3> echo "$PATH" /Users/me/scripts /Users/me/HOME/.cabal/bin /usr/local/sbin /usr/local/bin /usr/sbin /usr/bin /sbin /bin /usr/games /usr/X11R6/bin GUESS WHAT? It turns out you cannot temporily-set PATH in fish the way that normal shells have taught you to expect. I've learned my lesson to use 'env', but here is shown that PATH is downright broken in Fish. It is inherited as an environment variable that contains colons; I expect it to be spit out again as an environment variable that contains colons which work, not spaces that don't! If there's a secret way to do it anyway (I'd prefer to get colons and use the standard external tool 'env', than to use Fish-specific "set -lx" style stuff) , I'd appreciate hearing. but i've just about had it with fish: I love the syntax hilighting and history-searching, but it's - a few too irritating bugs, for a shell - needless incompatibility with bash, which makes copy-pasting and shell-scripting harder for me (I write bash scripts enough that I know all bash's idiosyncrasies better than any other shell/scripting language), while fish is not delivering me any of the suggested benefits (e.g. I had hoped, if 'begin' 'for' 'function' etc. were deliberately made to look like other statements, they would behave somewhat like other statements; but actually they're an unstoppable, syntactic, parser begin-bracket, a wolf in sheep's clothing. --help doesn't work; they affect the interactive parser/command-editor rather than having some simple non-creepy generalized way to deliberately enter multi-line commands; ...) Any suggestions for another shell with good syntax-hilighting and/or interactive history searching? (bonuses if it doesn't require the down-arrow key, because mine is broken :-P) Or will I be frustrated enough to write my own Bash-wrapping shell in Haskell? :-) (I guess the basic way to do that would involve my process spawning a "bash" process whose stdin consisting of command lines is attached to my process... I hope there aren't too many gotchas there; I wonder how terminal-seizing processes like 'less' work then...) lots of appreciations for fish's life, -Isaac ------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects _______________________________________________ Fish-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/fish-users
