If you want to render and publish your multilingual book or website with CI, you must render your project with render_book() or render_website(), respectively. Don’t use Quarto’s own render and publish steps. You can find more information about publishing with CI in the Quarto documentation.
Site URL
When you render a project in a CI context, you can set the URL of the publishing website in an environment variable (if different from the one in the _quarto.yml configuration file, as a preview for instance). You can do that with the BABELQUARTO_CI_URL environment variable.
For instance, for GitHub Actions, the workflow would contain these lines:
    env:
      BABELQUARTO_CI_URL: <the-url>Steps for rendering
To render your project with CI, you need to follow these general steps:
- Install the necessary dependencies including Quarto and R dependencies
- Render you project using {babelquarto}’s render_book()orrender_website()functions
- Publish the rendered HTML (_siteor_bookfolder) where you deploy your project (a GitHub pages branch, Netlify, etc.)
Publishing your project
Your Quarto multilingual website or book is a static website. To publish it, you need to deploy the output folder, i.e. _site or _book. That content can be served on any service, for instance GitHub Pages or Netlify.
Examples
Here are two examples of how you could render a multilingual book with CI using GitHub Actions:
- A demo Babelbook with its workflow file
- The rOpenSci Packages: Development, Maintenance, and Peer Review book with its workflow file
- The training materials for rOpenSci mentors, a website with its workflow file.
