Skip to content

Clean but avoiding cloning the source repository packages again? #8832

Open
@philderbeast

Description

@philderbeast

Is there a way to cabal clean without the next cabal build having to clone the source repository packages again? Can these clones be preserved?

$ cabal clean
$ cabal build
...
Cloning into '/.../dist-newstyle/src/amazonka...'
remote: Enumerating objects: 941841, done.
remote: Counting objects: 100% (171/171), done.
remote: Compressing objects: 100% (101/101), done.
remote: Total 941841 (delta 66), reused 151 (delta 59), pack-reused 941670
Receiving objects: 100% (941841/941841), 1.22 GiB | 28.97 MiB/s, done.
Resolving deltas: 100% (785798/785798), done.

I checked the help:

$ cabal clean --help
Clean the package store and remove temporary files.

Usage: cabal new-clean [FLAGS]

Removes all temporary files created during the building process (.hi, .o,
preprocessed sources, etc.) and also empties out the local caches (by
default).


Flags for clean:
 -h, --help                     Show this help text
 -v, --verbose[=n]              Control verbosity (n is 0--3, default
                                verbosity level is 1)
 --builddir=DIR                 The directory where Cabal puts generated build
                                files (default dist)
 --project-file=FILE            Set the name of the cabal.project file to
                                search for in parent directories
 -s, --save-config              Save configuration, only remove build
                                artifacts

Shouldn't this help now say (default dist-newstyle) now that the v2 commands are the default?

I tried --save-config but this didn't help.

Metadata

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