haskell / haskell/cabal

Optional VCS Support in `cabal sdist` (and all-in-one updist workflow)

Open
#5,064 10 comments 2 reactions 0 assignees View on GitHub
cabal-install: cmd/upload exact-print type: enhancement
Dominant language
Haskell
Stars
1.7k
Forks
750
Avg merge
4d 3h
Merged PRs (30d)
28

Description

It would be nice to have a one-step process for releasing packages. Suppose we had `cabal sdist --vcs`, initially configured to work with git alone, but easily extensible.

Running this would rely on the upstream repo in the cabal file being set correctly. Having done so it would:

* Confirm that the source-repo state matched the head of the branch
* Tag the branch, update the cabal file to point to the correct tag (using the sadly underused `tag` field component of the repo field), and push.
* build the tarball as usual with sdist

We could also add a `--test` flag that would unpack the tarball and attempt to build it (and if it has a test stanza, test it).

We could then add a new command, say `updist` that by default in order would `cabal sdist --test; cabal sdist --vcs; cabal sdist; cabal upload`, perhaps with flags to omit workflow steps. Not by default, but optionally it could have a flag to build and upload haddocks as well.

This is just quality of life, but I think it would make things much nicer, as the steps are all so mechanical, and always the same.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.