@@ -124,3 +124,69 @@ guarantees on top. Frictions specific to this package:
124124 explaining that ` codecarbon ` has no R equivalent and that setup is
125125 opt-in, confirmed, and isolated to its own conda environment rather
126126 than touching the user's system Python.
127+
128+ ### 4a. Step-by-step, once you decide to go for it
129+
130+ Pre-submission (in addition to the package-specific fixes above):
131+
132+ - [ ] Every exported function (` setup_carbon_tracker() ` , ` carbon_tracker() ` ,
133+ ` with_emissions_tracked() ` , ` list_carbon_tracker_countries() ` ,
134+ ` carbon_tracker_ready() ` ) needs an ` @examples ` block in its roxygen
135+ comment. None currently exist. Wrap any example that would call
136+ ` setup_carbon_tracker() ` , start a tracker, or otherwise touch
137+ Python/network in ` \donttest{} ` (runs on your machine, skipped on
138+ CRAN's checks) -- e.g. show ` list_carbon_tracker_countries() ` or
139+ ` carbon_tracker_ready() ` unwrapped since those don't touch Python,
140+ but wrap a ` with_emissions_tracked() ` example in ` \donttest{} ` .
141+ - [ ] Confirm ` Authors@R ` includes a copyright holder role -- add ` "cph" `
142+ to Beatrice Bock's ` role = c(...) ` in ` DESCRIPTION ` if it's only
143+ ` c("aut", "cre") ` currently (CRAN wants an explicit copyright holder,
144+ not just author/maintainer).
145+ - [ ] Write ` cran-comments.md ` at the repo root (` .Rbuildignore ` it if you
146+ don't want it in the built tarball, though CRAN's web form also asks
147+ for these comments directly). Cover: this is a first submission;
148+ what the package does in one line; and the Python/conda point noted
149+ above -- ` codecarbon ` has no R equivalent, ` setup_carbon_tracker() `
150+ is opt-in/interactive/confirmed and installs into its own isolated
151+ conda environment, never touches the user's system Python, and
152+ never runs during ` R CMD check ` (it errors intentionally in
153+ non-interactive contexts, which is what the test suite checks for).
154+ - [ ] From R, in the package directory:
155+ ```r
156+ usethis::use_version("minor") # bumps 0.0.0.9000 -> 0.1.0, tags NEWS.md
157+ devtools::check(remote = TRUE, manual = TRUE) # full local check
158+ devtools::check_win_devel() # builds on R's Windows dev servers, emails you the log
159+ urlchecker::url_check() # catches dead links in docs/README/vignette
160+ ```
161+ All three should come back clean (0 errors, 0 warnings, ideally 0
162+ notes) before submitting. ` check_win_devel() ` in particular catches
163+ things your local machine's R version won't.
164+ - [ ] Update ` NEWS.md ` 's heading from ` # CodeCarbonR (development version) `
165+ (or ` 0.0.0.9000 ` ) to the real version, and ` CITATION.cff ` 's
166+ ` version: ` /` date-released: ` to match.
167+
168+ Submission:
169+
170+ - [ ] ` devtools::submit_cran() ` -- builds the source tarball, uploads it
171+ to CRAN's submission form, and pulls maintainer info + your
172+ ` cran-comments.md ` content into the form automatically. (Manual
173+ alternative: build with ` R CMD build . ` , then upload the resulting
174+ ` .tar.gz ` yourself at
175+ [ cran.r-project.org/submit.html] ( https://cran.r-project.org/submit.html ) .)
176+ - [ ] ** (you)** CRAN emails a confirmation link to the maintainer address
177+ in ` DESCRIPTION ` -- click it. The submission doesn't enter the queue
178+ until confirmed.
179+ - [ ] Wait. CRAN's automated checks (multiple OSes/R versions) typically
180+ report back within a day or two; a human CRAN team member reviews
181+ after that. Total time is unpredictable -- same-day acceptances and
182+ multi-week back-and-forth both happen, and a package installing
183+ external software during setup (even opt-in) is exactly the kind of
184+ thing that can prompt a question rather than an immediate accept.
185+ - [ ] If CRAN comes back with required changes: fix them, bump the patch
186+ version again (e.g. ` 0.1.0 ` -> ` 0.1.1 ` ), add a line to
187+ ` cran-comments.md ` under a "Resubmission" heading explaining what
188+ changed, and resubmit the same way.
189+ - [ ] On acceptance: tag/release on GitHub if you haven't already (Section
190+ 2 above), then bump ` DESCRIPTION ` 's version to a new ` .9000 `
191+ development suffix (e.g. ` 0.1.0.9000 ` ) so it's clear ` main ` is past
192+ the released version.
0 commit comments