2 ms·
Yup, this way you can skip the shebang line for your scripts in some arbitrary language. I have it set up for Haskell (it's somewhat hackish): there is preconf
by kreetx 2y ago
Yup, this way you can skip the shebang line for your scripts in some arbitrary language.
I have it set up for Haskell (it's somewhat hackish): there is preconfigured haskell project in a certain location with desired dependencies, imports, etc., so when executing a .hs file this file is copied into that as Main and ran. A similar setup will work for any language.
Edit: `cabal` and `stack` both have script commands now, so these would be an alternative to the above, downside being that every such script would need the shebang intro with dependencies, etc.