[Haskell-beginners] Cross-platform .hs files on Linux and Windows

Vinay Sajip vinay_sajip at yahoo.co.uk
Tue Apr 17 21:24:27 CEST 2012


Henk-Jan van Tuyl <hjgtuyl <at> chello.nl> writes:

> 
> On my Windows XP system, the shebang line is ignored:
> 
> HashBang.hs:
> ----✁---------
> #!/usr/bin/env runhaskell
> 
> main = print "Hello!"
> ----✃---------
> 
> > runhaskell HashBang.hs
> "Hello!"
> 

Thank you for this information! I installed the platform on Windows XP
(32-bit), and I get the same result as you. The machine where I was having
the problems was a Windows 7 machine (64-bit), though I used the same
Haskell Platform installer on both.

Perhaps it's a Windows 7 issue, or a 32-bit vs. 64-bit issue. I'll try on a
different Windows 7 machine.

It's good to know that scripts are meant to be cross-platform on Linux and
Windows.

Regards,

Vinay Sajip




More information about the Beginners mailing list