-
Notifications
You must be signed in to change notification settings - Fork 723
Open
Labels
Description
Describe the feature request
With a project, allow cabal repl to default the target when none is given in these two cases:
- If there is only one package in the project use that as the target.
- If there is more than one package and
--enable-multi-replis an option then pickallas the target.
Additional context
When we are working with a package, cabal repl needs no target.
$ cabal unpack Cabal-syntax
Warning: this is a debug build of cabal-install with assertions enabled.
Downloading Cabal-syntax-3.16.1.0
Downloaded Cabal-syntax-3.16.1.0
Unpacking to Cabal-syntax-3.16.1.0/
$ cd Cabal-syntax-3.16.1.0/
$ cabal repl
Warning: this is a debug build of cabal-install with assertions enabled.
Resolving dependencies...
Build profile: -w ghc-9.12.2 -O1
In order, the following will be built (use -v for more details):
- alex-3.5.4.0 (exe:alex) (requires build)
- Cabal-syntax-3.16.1.0 (interactive) (lib) (first run)
Starting alex-3.5.4.0 (exe:alex)
Building alex-3.5.4.0 (exe:alex)
Installing alex-3.5.4.0 (exe:alex)
Completed alex-3.5.4.0 (exe:alex)
Warning: this is a debug build of cabal-install with assertions enabled.
Configuring library for Cabal-syntax-3.16.1.0...
Warning: this is a debug build of cabal-install with assertions enabled.
Preprocessing library for Cabal-syntax-3.16.1.0...
GHCi, version 9.12.2: https://www.haskell.org/ghc/ :? for help
when making flags consistent: warning: [GHC-74335] [-Winconsistent-flags]
Ignoring optimization flags since they are experimental for the byte-code interpreter.
Pass -fno-unoptimized-core-for-interpreter to enable this feature.
[ 1 of 139] Compiling Distribution.Compat.Binary
...
[139 of 139] Compiling Distribution.InstalledPackageInfo
Ok, 139 modules loaded.
ghci>