Skip to content

Expect to be run at project root #69

@nomeata

Description

@nomeata

I hit this problem when trying to use the getPackageExtentions function pointing to a cabal file that is not my current directory, but I can also exhibit it using the CLI:

…/ext-stats $ extensions --cabal-file-path hackage/3dmodels-0.3.0/*.cabal 
  ⓘ Extensions for each module combined with 'default-extensions'
…/ext-stats $ cd hackage/3dmodels-0.3.0
…/hackage/3dmodels-0.3.0 $ extensions --cabal-file-path *.cabal
  ⓘ Extensions for each module combined with 'default-extensions'
Graphics/Model/DirectX.hs
    OverloadedStrings
    RecordWildCards
Graphics/Model/MikuMikuDance.hs
Graphics/Model/MikuMikuDance/Loader.hs
    OverloadedStrings
Graphics/Model/MikuMikuDance/Types.hs
Graphics/Model/Obj.hs
    OverloadedStrings
    TupleSections

I would expect it to find the source code relative to the given cabal file.

Also, as a feature request, it might be nice if I can just pass a path to a directory, and it will use the (existing) logic to find the .cabal file therein.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions