Skip to content

cabal new-run foo should default to exe:foo (same for test and bench) #4676

Closed
@nomeata

Description

@nomeata

If I have a project foo.cabal that defines both a library and an executable named foo, which is a common situation, then currently

$ cabal new-run foo -- some args

complains that it does not know whether I want to run foo the library or foo the executable, and makes me write

$ cabal new-run exe:foo -- some args

I see how this behavior makes sense for cabal new-build etc, but I do not even know what it means to cabal new-run a library. And even if that makes sense, I believe the ambiguity should just be resolved to the executable by default.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions