<div dir="ltr"><div class="gmail_extra">Hi Michael,</div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Sep 26, 2016 at 12:32 PM, Michael Snoyman wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>For those wanting to have direct access to GHC and other such tools, without needing to prefix calls with `stack exec -- `, the following added to your ~/.bashrc (or equivalent) will do the trick:</div><br>    export PATH=`stack path --bin-path`</blockquote></div><br>This is not the side-effect-free function I expected it to be. I just tried it on a Mac after a new install of stack:</div><div class="gmail_extra"><br></div><div class="gmail_extra"><div class="gmail_extra"><div class="gmail_extra">    $ stack path --bin-path</div><div class="gmail_extra">    Run from outside a project, using implicit global project config</div><div class="gmail_extra">    Using resolver: lts-7.0 from implicit global project's config file: ~/.stack/global-project/stack.yaml</div><div class="gmail_extra">    Fetched package index.</div><div class="gmail_extra">    Populated index cache.</div><div class="gmail_extra">    No compiler found, expected minor version match with ghc-8.0.1 (x86_64) (based on resolver setting in /Users/leather/.stack/global-project/stack.yaml).</div><div class="gmail_extra">    Try running "stack setup" to install the correct GHC into ~/.stack/programs/x86_64-osx/</div><div><br></div><div>The above took nearly 10 minutes and failed. I would not recommend doing that in a ~/.bashrc.<br></div><div><br></div></div><div class="gmail_extra">See <a href="https://github.com/commercialhaskell/stack/issues/2325">https://github.com/commercialhaskell/stack/issues/2325</a> for the issue I reported in July.</div><div class="gmail_extra"><br></div><div class="gmail_extra">Regards,</div><div class="gmail_extra">Sean</div></div></div>