[Haskell-cafe] On Windows after I install the new cabal-install then when I do a cabal update it says there is a new ...

KC kc1956 at gmail.com
Mon Jul 13 18:21:48 UTC 2015


I created a Cabal variable with the path to cabal\bin in the system
variables area and than put that early in the Path variable

Cabal update now finds the new cabal-install

What are the pros and cons of doing this?

I have a feeling running batch scripts to set path variables might be
better to avoid long path variables and to inadvertently finding the wrong
files on long path variables.

I have also found that you want to install most/all programming platforms
outside of the Program Files folder which Windows has special protections
on.

--
--

Sent from an expensive device which will be obsolete in a few months! :D

Casey

On Jul 13, 2015 10:57 AM, "Michael Steele" <mikesteele81 at gmail.com> wrote:

> I disagree that this is a bug or misfeature in the Haskell Platform. The
> problem is caused by a quirk in how Windows works.
>
> There are a few other options I didn't mention. One is to delete the
> global entry from the 'system' path variable and insert it into the 'user'
> path variable somewhere after the "%appdata%\cabal\bin" entry. The downside
> here is that other user accounts will be affected. Another option is to use
> a custom shortcut or execute a batch script which manually sets PATH
> variables as needed. This is the method I use personally.
>
>
> On Mon, Jul 13, 2015 at 10:01 AM, Sven Panne <svenpanne at gmail.com> wrote:
>
>> 2015-07-13 18:41 GMT+02:00 Michael Steele <mikesteele81 at gmail.com>:
>>
>>> On Windows the 'system' path variable always has precedence over the
>>> 'user' path variable (see [1]). You will need to rename, delete, or
>>> overwrite the version of cabal.exe installed globally for the one under
>>> %appdata% to be used.
>>>
>>>
>>> [1]: https://support.microsoft.com/en-us/kb/100843
>>>
>>
>> To me that looks like a bug in the Haskell Platform installer: It puts
>> the path to the tools shipped with the platform into the the system PATH
>> and the path to the user-installed tools (i.e. the stuff below %APPDATA%)
>> into the user part of the PATH. This way, you will always get the shipped
>> alex/cabal/happy/HsColour, not the new stuff. This is a bit like putting
>> e.g. /usr/bin before your $HOME/bin on *nices, which is exactly the wrong
>> way round.
>>
>> Furthermore, I've just seen that there is a 'C:\Program
>> Files\Haskell\bin' at the start of my system PATH, pointing to nowhere. Is
>> this a remnant of former GHC/platform installations? No clue where this
>> comes from...
>>
>
>
>
> --
> -- Michael Steele
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/haskell-cafe/attachments/20150713/3ce5cf50/attachment.html>


More information about the Haskell-Cafe mailing list