"contents": "\r\nThe usethis package and the RStudio IDE will help you orchestrate your version control repositories as RStudio projects.\r\n\r\n\r\n\r\n\r\nSetup\r\nTo get started, make a free GitHub.com account. Make sure you have the latest versions of R, RStudio, and usethis. Then, setup your RStudio configuration using two key documents: Setup, and Managing Git(Hub) Credentials.\r\nTips\r\nClone or fork from GitHub\r\n\r\n\r\nusethis::create_from_github(\"https://github.com/data-and-visualization/git-tutorial\")\r\n\r\n\r\n\r\nCreate the GitHub repo from local\r\n\r\n\r\nlibrary(usethis)\r\nuse_git() # initialize a git repo\r\nuse_git_ignore()\r\nuse_readme.Rmd()\r\nuse_ccby_license()\r\nuse_github() # Connect local repo to GitHub\r\n\r\n\r\n\r\nset-up git and manage GitHub credentials\r\n\r\n\r\n# Sign-in to your GitHub account\r\n# Read: https://usethis.r-lib.org/articles/articles/git-credentials.html\r\n# Read: https://usethis.r-lib.org/articles/articles/usethis-setup.html\r\nusethis::create_github_token()\r\ngitcreds::gitcreds_set()\r\ngh::gh_whoami()\r\nusethis::git_sitrep()\r\nusethis::use_git_config(user.name = \"Jane Doe\", user.email = \"
[email protected]\")\r\ngh::git_sitrep()\r\n\r\n\r\n\r\nNext Level…\r\nTake your reproducibility to the next level. Make your code citable by connecting your GitHub repo and your ORCID (unique author ID) through to the Zenodo archival repository. Now, every time you commit a milestone release, you also mint a DOI.\r\nContainerize your repository with binder.org using the holepunch package.\r\nQuick_Publish your code in a binder.org container\r\nUse the holepunch package\r\n\r\n\r\nlibrary(holepunch)\r\n\r\nwrite_compendium_description()\r\nwrite_dockerfile()\r\ngenerate_badge()\r\nbuild_binder()\r\n\r\n\r\n\r\nBespoke_Publish your code in a binder\r\nI recently found my QuickPublish approach didn’t quite work. So I RTFMed the binder.org docs and it seemed to imply a preference for NOT using a .binder/Dockerfile. Therefore, here is an approach that is slightly less automated but more bulletproof.\r\nStep 1\r\n\r\n\r\nholepunch::write_compendium_description() # output is a DESCRIPTION file in the project root\r\nholepunch::write_runtime() # output is .binder/runtime.txt\r\nholepunch::write_install() # output is .binder/install.R\r\nholepunch::generate_badge() # output is a badge to be found in the README file(s)\r\n\r\n\r\n\r\nStep 2\r\nEdit the .binder/install.R file using the following model.\r\nEdit the binder/install.R file based on this model or the documentation\r\nEdit the DESCRIPTION file using this basic model. Modify all the fields. You may want to base the Depends and Remotes sections on your .binder/install.R file\r\nThe old documentation from this site can be found in the v.0.2019 release on GitHub.\r\n\r\n\r\n\r\n",
0 commit comments