A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/haskell/cabal/issues/6622 below:

`cabal repl file` fails for executable component · Issue #6622 · haskell/cabal · GitHub

To Reproduce
Steps to reproduce the behavior:
Set up an example project:

$  cabal init -p example --libandexe --tests --main-is=Main.hs --source-dir=src --application-dir=app --test-dir=test

Load library component:

$ cabal repl src/MyLib.hs
# Succeeds to load
$ cabal repl src/Lib.hs
# Fails to load as expected 
$ cabal repl app/Main.hs
# Fails to load although
cabal.exe: Unknown target './app/Main.hs'.
The package example has no file target 'app/Main.hs'.
$ cabal repl test/MyTestLib.hs
cabal.exe: Unknown target './test/MyLibTest.hs'.
The package example has no file target 'test/MyLibTest.hs'.

Expected behavior

The file targets app/Main.hs and test/MyTestLib.hs should successfully load.

System information

Benefit

Directly benefits hie-bios which uses cabal repl <filename> to find compilation flags.
cc @mpickering


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4