Skip to content

πŸš€ Release Process

Paolo Di Lorenzo edited this page Mar 18, 2024 · 4 revisions

Automated Process

This is the automated release process. The steps listed here will also appear in the automatically generated pull request as checklists.

1. Run release workflow

  • Navigate to the release.yaml workflow
  • Select Run workflow
  • Enter the version number for the release in the box (e.g. 0.7.2, 1.2.5, etc.)
  • Wait for pipeline to finish

2. Complete pre-release checklist

The aforementioned workflow will create a pull request with the version changes and some checklists.

  • Complete all the steps in the pre-release checklist and make any changes to the pull request as needed.

3. Submit package to CRAN

  • Update cram-comments.md
  • Run `devtools::release()
  • Perform CRAN release steps, usually received via the maintainer's email
  • If CRAN requires changes, make the changes on the pull request's branch, add them to the pull request, and resubmit.

4. Complete post-release checklist

In the pull request created for the release, complete all items in the post-release checklist.

5. Merge the Pull Request

If the release goes well and all items are checked off, merge the pull request.


Manual Steps

⚠️ These steps should only be followed if the automated workflow is not working for some reason.

These are the manual steps to follow when releasing a new version of the package to CRAN:

(these steps also apply to the usmapdata package)

1. Create release branch

  • git checkout -b release/x.x.x where x.x.x is the new version number

2. Run other platform checks

  • devtools::check_rhub()
  • devtools::check_win_devel()

3. Check reverse dependencies

  • > revdepcheck::revdep_reset()
  • > revdepcheck::revdep_check()

4. Update cran-comments.md

  • Update version numbers (ubuntu, R, etc)
  • Update reverse dependencies list
  • Update R CMD check results
  • Add any important things for CRAN to consider when reviewing the package (if necessary)
  • Add explanations for WARNINGS or NOTES (if necessary)

5. Update NEWS.md

  • Ensure all release notes are included and accurate (with associated GitHub issue linked if applicable)
  • Update version number

6. Update DESCRIPTION

  • Update version number
  • Ensure description and metadata is accurate

7. Spellcheck

  • > devtools::spell_check()
  • Fix any misspelled words (note some results may be false positives and can be ignored)

8. Commit all changes for release

  • Commit message should be Prepare for x.x.x release
  • Push branch and open pull request git push -u origin release/x.x.x
  • Ensure all GitHub Actions workflows pass

9. Release package

  • > devtools::release()
  • Follow all release steps
  • If any issues are encountered make and commit appropriate changes and re-run devtools::release()

10. Post-approval Items

After the package is accepted and published on CRAN:

  • > git tag vx.x.x where x.x.x is the new version
  • > git push --tags
  • Update DESCRIPTION and NEWS.md versions to x.x.x.9999
  • Add release date of latest version to NEWS.md
    • Example Released Monday, February 31, 2020.
  • Commit changes with message Prepare for next release
  • Merge release/x.x.x to master
  • > usethis::use_github_release()