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.