Preliminary work before the final is ready.
devtools::check(document = FALSE, vignettes=FALSE)
devtools::run_examples(pkg="~/Documents/GitHub/MARSS", document=FALSE, fresh=TRUE)
#devtools::install_github("ropensci/spelling")
spelling::spell_check_package()
fils <- dir("vignettes/manual_files", full.names = TRUE)
fils <- fils[stringr::str_detect(fils, "Rnw")]
spelling::spell_check_files(fils, ignore = spelling::get_wordlist(pkg = "."), lang = "en_US")
setwd("~/Documents/GitHub")
devtools::build_manual(pkg="MARSS")
Documentation
Follow instructions in DEVELOPER_NOTES.md in inst to prepare the documentation pdfs
Compress documentation pdfs
Build final tar.gz
Run version tests
cd ~/Dropbox
rm -r ~/Dropbox/MARSS.Rcheck
R CMD check --timings --as-cran MARSS_3.11.9.tar.gz
Run internal tests on the new tar.gz
Check the documentation pdfs and html files in Dropbox/MARSS/inst/doc
If needed compress documentation pdfs some more
R CMD build --no-build-vignettes MARSS
rm -r ~/Dropbox/MARSS.Rcheck
R CMD check --timings --as-cran MARSS_3.11.9.tar.gz
Finally update the doc folder for GitHub. This has to be done manually by copying from
Prepare for release:
Update the doc folder on GitHub. This has to be done manually
Re-read the submission guidelines to see if anything changed: https://cran.r-project.org/submit.html
Check that package builds on Windows
Upload package to CRAN
The items below are for cases where you are submitting the package files without any extra processing. I process my vignette PDFs separately, so the below won't work.
devtools::check_win_devel()
rhub::check_for_cran()
revdepcheck::revdep_check(num_workers = 4)
Instead use
- The link to check the tar.gz file on Windows.
rhub::check_for_cran("../rhub::check_for_cran("../MARSS_3.11.9.tar.gz") on the processed tar.gz file
Submit to CRAN:
You could do this, but I upload the tag.gz to CRAN
usethis::use_version('patch')
devtools::submit_cran()
- Approve email
Wait for CRAN...
Preliminary work before the final is ready.
Documentation
Follow instructions in DEVELOPER_NOTES.md in
instto prepare the documentation pdfsCompress documentation pdfs
Build final tar.gz
instto prepare the tar.gz file. That has a makefile (inst/makefile) that has all the steps to prepare the tar.gz properly. Also the userguide and derivations folders have make files for creating those. Note do not usedevtools::build()it destroys theinst/docfolder. Note, the Mac LaTeX installation doesn't install packages on the fly. You may need to install the needed packages. From terminal:tlmgr install imakeindex,tlmgr install collection-fontsrecommended,tlmgr install footmisc, tlmgr install appendix`, plus a few more in header.tex.Run version tests
Run this
vignettes/versiontest.RRun checks on the built package
Run internal tests on the new tar.gz
tests/model.Rto set up models for testsdevtools::test()but I find running the tests one by one in RStudio is easier to make sense of. Some tests will through errors, but all test should pass. Errors are correct if the test passes and result should be try-error.Check the documentation pdfs and html files in Dropbox/MARSS/inst/doc
If needed compress documentation pdfs some more
Finally update the doc folder for GitHub. This has to be done manually by copying from
Prepare for release:
urlchecker::url_check()Update the doc folder on GitHub. This has to be done manually
Re-read the submission guidelines to see if anything changed: https://cran.r-project.org/submit.html
Check that package builds on Windows
Upload package to CRAN
The items below are for cases where you are submitting the package files without any extra processing. I process my vignette PDFs separately, so the below won't work.
devtools::check_win_devel()rhub::check_for_cran()revdepcheck::revdep_check(num_workers = 4)Instead use
rhub::check_for_cran("../rhub::check_for_cran("../MARSS_3.11.9.tar.gz")on the processed tar.gz fileSubmit to CRAN:
You could do this, but I upload the tag.gz to CRAN
usethis::use_version('patch')devtools::submit_cran()Wait for CRAN...