We updated our techguides to reflect new features of renv
, rsconnect
and GitHub Actions, describing state-of-the-art best practices.
Mirai Solutions is sharing technical guidelines at mirai-solutions.ch/techguides, a bookdown
website hosted on GitHub Pages from a public GitHub repository. There, we collect how-to-s and best practices in different areas, including R and Shiny development. Our insights are based on our practical project experience and aim at providing concrete, practical guidance to approaching certain common problems and aspects of the R and Shiny software development lifecycle.
When developing an application it is first of all important to control the development processes to ensure that all involved developers are working in the same reproducible and stable environment, and at the same time to rely on automated pipelines that can provide Continuous Integration (CI) and Deployment (CD).
The R community has been quite active, particularly in recent years, in providing the right development tools in the R ecosystem to achieve these goals. Such tools are being constantly maintained and enhanced with new features to face new challenges.
- Package
renv
provides support creating reproducible environments for R projects. - The r-lib/actions repository defines GitHub Actions for a variety of CI tasks.
- Package
rsconnect
allows publishing Shiny Apps, R Markdown, Quarto documents and Plumber APIs, on provided servers like shinyapps.io or Posit Connect.
Relevant major enhancements have been implemented in all these tools during 2023, which have bee incorporated in our technical guidelines chapters ‘Control dependencies with renv
’ and (‘CI/CD pipelines for automatic deployment of a R Shiny web app’, to be aligned with the state-of-the-art tools and best practices.
renv
initialization has new features and functions we can make use of, and has improved its approach to development packages, which can be now easily included/excluded from the configuration.- Updated Versions of GitHub Actions allow the simplification of
yml
workflows for CI/CD. - Deployment with
rsconnect
is now better tailored torenv
projects, allowingrenv
to resolve the package dependency tree also on deployment.
Browse through the Technical Guide’s chapters, give us feedback, and let us know if you would like to have other topics addressed.
If you want to have a guided, hands-on experience in applying the best practices for the operations described in our guide, you may consider our upcoming series of workshops about R and Shiny development (April-May 2024).
Let our techguides help you work on your R project, control package dependencies and set up efficient and easy-to-use CI/CD workflows for your R and Shiny applications!