[Haskell-cafe] Ported a Python script for use with Go to Haskell
Kim-Ee Yeoh
ky3 at atamo.com
Sat Apr 5 16:36:40 UTC 2014
On Sat, Apr 5, 2014 at 11:17 PM, Matt Joiner <anacrolix at gmail.com> wrote:
> I considered the same thing with an existing GOBIN env var. I did actually
> test it and found it worked as expected.
Omg, color me surprised!
> Items earlier in the list seem to have higher priority.
I'd drill deeper into this to find out why if I had the time, but in any
case, are you sure you want to rely on such brittle, undocumented behavior?
Goerzen's MissingH has an addToAL that's perfect for the job:
origEnv <- getEnvironment
let clobberedEnv = addToAL origEnv "GOBIN" dest
I prefer not to use setenv, because I want to exec into the binary later
> without GOBIN clobbered, which means keeping the current environment
> pristine. Good point about it not matching the Python version, but then a
> few other things don't either now. :)
Fair enough. :)
-- Kim-Ee
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20140405/1a3b6713/attachment.html>
More information about the Haskell-Cafe
mailing list