fledge icon indicating copy to clipboard operation
fledge copied to clipboard

Atomic pre_release()

Open krlmlr opened this issue 2 years ago • 0 comments

There are a few ways where pre_release() can fail:

  • [ ] GITHUB_PAT not set (should we use gitcreds)?
  • [ ] The remote is not a GitHub remote (we should leave out the PR creation but otherwise continue)
  • [ ] Not on main branch
  • [ ] Main branch not up to date
  • [ ] cran-x.y.z branch exists locally
  • [ ] cran-x.y.z branch exists on the remote (a failed pre_release() attempt perhaps?)
  • [ ] A pull request for the branch already exists
  • [ ] Tag vx.y.z exists locally
  • [ ] Tag vx.y.z exists on the remote
  • [ ] Version >= x.y.z already on CRAN
  • [ ] ...

Ideally we would do a preflight check that aborts early without taking any action. Alternatively, we could support an undo function that cleans up everything to the state it was just before the attempted release.

krlmlr avatar Feb 17 '22 20:02 krlmlr