Closed
Description
- From the recent experience we know that:
- Users needs a hackage release for every github release we do: Will 0.9.0 and future releases be uploaded to hackage? #1282
- The hackage release is cumbersome and error prone and involve the coordination of several contributors, see prepare 0.9.0 hackage release #1287 and Upload to Hackage #1175
- So we have to automate the process as much as we can, making the automating process itself lightweight if possible
The steps needed to make the release are:
- Identify changes of each subpackage and check if they can break downstream ones
- Bump up the package version accordingly and propagate it to the bounds of downstream packages
- Make pr(o several prs) with those changes, ensuring the order of dependencies
- Cherry pick those changes onto the github release commit as a branch
- Check the subpackage builds succesfully in that branch (and test it?)
- Do a
cabal check && cabal haddock subpackage && cabal sdist subpackage
- Do a
cabal upload subpackage
(we can use https://github.com/haskell-actions/hackage-publish)
I think the steps 5, 6 and 7 could be automated in ci, uploading package candidates to do a final review and publish all of them.
Not sure how could we automate 1-4 though. Maybe doing a git diff
per subpackage and update version bounds of .cabal files with some form of grep&sed (bumping out version as always breaking with no fine grained pvp considerations as suggested by @michaelpj)
There are projects with lot of subpackages and maybe they have been some work to automate this, as pointed by @wz1000.
For example amazonka. Afaics they have a Makefile that includes upload of packages: https://github.com/brendanhay/amazonka/blob/develop/Makefile