You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Often, I want to send someone a small Haskell file to open in the interpreter for e.g. a bug report against a library or a StackOverflow answer. It'd be nice to be able to use the shebang system (or something like it) and have Stack open the file in ghci with the appropriate packages/GHC/etc in place. Concretely, this script
Changing ghci to runghc runs it as expected. Running stack ghci ~/junk/unbound-bug.hs results in Error parsing targets: Directory not found: /home/enolan/junk/unbound-bug.hs regardless of if the file has runghc or ghci in it. Ideally, both stack ghci $FILENAME and writing ghci instead of runghc in the header comment would open the interpreter shell.
Version 1.1.2, Git revision cebe10e845fed4420b6224d97dcabf20477bbd4b (3646 commits) x86_64 hpack-0.14.0
The text was updated successfully, but these errors were encountered:
Interpreter does not allow commands other than runghc. I contemplated allowing ghci case in interpreter but was wondering if someone would need this and here you are. I will happily enable this.
Another problem is that stack ghci does not work as you would think on single files. You can use stack exec ghci though.
On Wed, Aug 17, 2016, 8:45 PM Harendra Kumar [email protected]
wrote:
Interpreter does not allow commands other than runghc. I contemplated
allowing ghci case in interpreter but was wondering if someone would need
this and here you are. I will happily enable this.
Another problem is that stack ghci does not work as you would think on
single files. You can use stack exec ghci though.
Often, I want to send someone a small Haskell file to open in the interpreter for e.g. a bug report against a library or a StackOverflow answer. It'd be nice to be able to use the shebang system (or something like it) and have Stack open the file in ghci with the appropriate packages/GHC/etc in place. Concretely, this script
fails with
Changing
ghci
torunghc
runs it as expected. Runningstack ghci ~/junk/unbound-bug.hs
results inError parsing targets: Directory not found: /home/enolan/junk/unbound-bug.hs
regardless of if the file hasrunghc
orghci
in it. Ideally, bothstack ghci $FILENAME
and writingghci
instead ofrunghc
in the header comment would open the interpreter shell.Version 1.1.2, Git revision cebe10e845fed4420b6224d97dcabf20477bbd4b (3646 commits) x86_64 hpack-0.14.0
The text was updated successfully, but these errors were encountered: