Contributing
Source:CONTRIBUTING.md
Workflow
- Open an issue or discussion before large behavioral changes.
- Add or update tests for every user-visible change.
- Keep exported function signatures and object shapes stable unless the change is explicitly planned as breaking.
- Prefer small, reviewable patches over broad rewrites without coverage.
Constraints
- Do not alter the Punycode helpers (
.normalize_and_punycode(),.punycode_to_unicode()) or their hardcoded TLD workarounds. SeeCLAUDE.mdfor the full list of protected areas and the intentional base-R string exceptions. - Public Suffix List data, its parsing, and its refresh (
pslr::psl_refresh()) live in thepslrpackage.rurlships no PSL list of its own and queriespslrthrough theR/domain.Rseam. SeeCLAUDE.mdfor the delegation contract.
Validation
- Run
devtools::test()locally for every change. - For packaging changes, run
R CMD check --as-cranbefore release work. - New prose in
DESCRIPTION,.Rd, README, or vignettes should passspelling::spell_check_package(); add genuine terms toinst/WORDLIST.
CRAN release checklist
Follow these steps in order for every CRAN release. The first three and the fast-forward are the easiest to miss — skipping them leaves NEWS.md, the published version, and main out of sync.
-
Update the NEWS heading. Ensure the top
NEWS.mdheading matches the release version (e.g.## rurl 1.2.0) and fold any unreleased items into that section. Thenews-versionCI check enforces that the top NEWS heading is either(development version)or theDESCRIPTIONVersion. -
Set the release version in
DESCRIPTION. - Update
cran-comments.mdfor this submission. - Run
R CMD build . && R CMD check --as-cran rurl_*.tar.gzclean; confirm the platform CI (R-CMD-check, R-hub) is green. - Submit to CRAN. Once accepted, tag the released commit (
git tag -a vX.Y.Z) and push the tag. -
Fast-forward
mainto the released/tagged commit so the default branch always reflects what shipped (git merge --ff-only vX.Y.Z && git push). Verify:git merge-base vX.Y.Z mainequals the tag. - Create the GitHub Release from the tag.
- Open a post-release PR that (a) bumps
DESCRIPTIONto the next development version, (b) adds a fresh## rurl (development version)NEWS heading, and- adds the CRAN canonical URL to the
DESCRIPTIONURL:field (https://CRAN.R-project.org/package=rurl), which only exists once accepted.
- adds the CRAN canonical URL to the
- Sanity check: diff the published CRAN tarball (
cran.r-project.org/src/contrib/rurl_X.Y.Z.tar.gz) against the tag — only CRAN’s auto-addedDESCRIPTIONfields should differ.