Skip to content

cabal init: --package-dir seems to be ignored #9157

Open
@ffaf1

Description

Describe the bug
cabal init --package-dir some-dir does not work (does not work = the files do not get written inside some-dir).

To Reproduce

f@mkiii:~/download$ cabal init --package-dir=/tmp/app/ -nm
Warning: this is a debug build of cabal-install with assertions enabled.
[Log] Guessing dependencies...
[Log] Using cabal specification: 3.0
[Warning] unknown license type, you must put a copy in LICENSE yourself.
[Log] Creating fresh file CHANGELOG.md...
[Log] Creating fresh directory ./app...
[Log] Creating fresh file app/Main.hs...
[Log] Creating fresh file app.cabal...
[Warning] No synopsis given. You should edit the .cabal file and add one.
[Info] You may want to edit the .cabal file and add a Description field.

f@mkiii:~/download$ lsc
app  app.cabal  CHANGELOG.md
f@mkiii:~/download$ ls /tmp/app/
f@mkiii:~/download$

Expected behavior
After running cabal init --package-dir=/tmp/app/ -nm, I want folders, cal files etc. to be written in /tmp/app.

System information

  • Debian bookworm
  • cabal 3.11, ghc 9.2.8

Additional context

--help entry for --package-dir

 --package-dir=DIRECTORY        Root directory of the package (default =
                                current directory).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions