-
Notifications
You must be signed in to change notification settings - Fork 5
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Summary
The recent versions of cabal-gild
discover
s modules not only in DIRECTORY
but also in .
.
In particular, we need --exclude=Setup.hs
to avoid cabal's Setup module is wrongly included.
Version Info
cabal-gild-1.5.0.0
- macOS Sonoma 14.5
- MacBook Pro with Apple M3 Pro chip
Reproduction Procedure
Suppose we have the project with the following structure:
-
/gild-setup.cabal
with the following content:cabal-version: 2.2 name: gild-setup version: 0.1.0.0 homepage: https://github.com/konn/gild-setup#readme author: Hiromi ISHII maintainer: konn.jinro_at_gmail.com copyright: 2024 (c) Hiromi ISHII category: Web build-type: Simple library hs-source-dirs: src -- cabal-gild: discover src exposed-modules: build-depends: base >=4.7 && <5
-
Setup.hs
:import Distribution.Simple main = defaultMain
-
src/Lib.hs
module Lib () where
Then, in the project root, run:
cabal-gild --io gild-setup.cabal
Expected behaviour
The field exposed-modules
must be expanded to:
-- cabal-gild: discover src
exposed-modules: Lib
Actual behaviour
It contains Setup
too:
-- cabal-gild: discover src
exposed-modules:
Lib
Setup
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working