Skip to content

Commit 6b4963b

Browse files
committed
doc: renv.lock update
1 parent 8141a5a commit 6b4963b

File tree

3 files changed

+194
-483
lines changed

3 files changed

+194
-483
lines changed

README.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ Prior to beginning this guide, you should also review the script shown in the ac
3030
- [Citation](#citation)
3131
- [License](#license)
3232

33-
## Features {#features}
33+
## Features
3434

3535
- **TIER Protocol 4.0 Structure:** Organized folder structure (`Data/`, `Scripts/`, `Output/`) aligned with the [TIER Protocol](https://www.projecttier.org/tier-protocol/protocol-4-0/) for clear reproducibility.
3636
- **Quarto Book Project:** Utilizes [Quarto's powerful book format](https://quarto.org/docs/books/) for creating rich, dynamic documents integrating text, code (R), and outputs.
@@ -42,7 +42,7 @@ Prior to beginning this guide, you should also review the script shown in the ac
4242
- **Easy Deployment:** Configured for publication on GitHub Pages (gh-page branch) via GitHub Actions (`.github/workflows/deploy.yml`).
4343
- **Sharing Platform:** Designed for sharing on the [Open Science Framework (OSF)](https://osf.io/).
4444

45-
## Prerequisites {#prerequisites}
45+
## Prerequisites
4646

4747
Before using this template for **Full Reproducibility**, ensure you have the following installed on your machine:
4848

@@ -80,7 +80,7 @@ This method uses the pre-configured Docker setup for the easiest and most reprod
8080
- **Windows:** Double-click `stop.bat`.
8181
- **macOS/Linux:** Run `./stop.sh`.
8282

83-
## Setup, Build, and Run (Detailed Docker Steps) {#setup-build-and-run-detailed-docker-steps}
83+
## Setup, Build, and Run (Detailed Docker Steps)
8484

8585
If you prefer manual control or want to understand the process:
8686

@@ -93,14 +93,14 @@ If you prefer manual control or want to understand the process:
9393
4. **Stop the Container:**
9494
- To stop and remove the container: `docker-compose down`
9595

96-
## Accessing the RStudio Environment {#accessing-the-rstudio-environment}
96+
## Accessing the RStudio Environment
9797

9898
- **URL:** `http://127.0.0.x:8787` (The `start` scripts automatically open this).
9999
- **Authentication:** No login required (`DISABLE_AUTH=true`).
100100
- **User:** You are logged in as the `rstudio` user.
101101
- **Project Location (in Container):** `/home/rstudio/project` (This is your local project folder mounted inside the container).
102102

103-
## Daily Workflow {#daily-workflow}
103+
## Daily Workflow
104104

105105
1. **Start:** Use `docker/start.bat` or `docker/start.sh`.
106106
2. **Work in RStudio:**
@@ -112,19 +112,19 @@ If you prefer manual control or want to understand the process:
112112
- Use `quarto render` in the Terminal to build your outputs (HTML, PDF).
113113
3. **Stop:** Use `docker/stop.bat` or `docker/stop.sh` when done.
114114

115-
## Environment Features {#environment-features}
115+
## Environment Features
116116

117117
- **Base Image:** `rocker/verse:4.5.1` (Includes R, RStudio Server, Quarto, Pandoc, TinyTeX).
118118
- **R Package Management:** `renv` is pre-configured.
119119
- **Library Path:** `/renv/library` (Mounted as a Docker volume for persistence).
120120
- **Cache Path:** `/renv/cache` (Mounted as a Docker volume for faster reinstalls and sharing between projects).
121121
- **Packages:** Core packages defined in `renv.lock` are restored during the Docker image build for the first render.
122-
- **LaTeX/TinyTeX:** Essential LaTeX packages (`amsfonts`, `unicode-math`, `booktabs`, `caption`, `float`) are pre-installed in the Docker image.
122+
- **LaTeX/TinyTeX:** Essential LaTeX packages are pre-installed in the Docker image and persist in the `texlive_data` volume.
123123
- **Data Persistence:** Your project directory (`..` relative to `docker/`) is mounted to `/home/rstudio/project`.
124124
- **RStudio Settings Persistence:** RStudio configuration (`.config`, `.local`, `.rstudio`, `.R`) is stored in `docker/cache/` and mounted into the container, preserving your layout and preferences per project.
125125
- **Port Management:** The `start` scripts automatically find an open port starting from `127.0.0.1:8787`.
126126

127-
## Useful Commands {#useful-commands}
127+
## Useful Commands
128128

129129
- **Inside RStudio Terminal:**
130130
- `quarto render`: Render the entire book/project.
@@ -138,7 +138,7 @@ If you prefer manual control or want to understand the process:
138138
- `docker volume ls`: List Docker volumes (to see `renv_cache`, `renv_library`).
139139
- `docker volume prune`: Remove unused Docker volumes (use with caution).
140140

141-
## Troubleshooting {#troubleshooting}
141+
## Troubleshooting
142142

143143
- **Docker not running:** Ensure the Docker Desktop application (or Docker daemon on Linux) is started.
144144
- **Port in use:** The `start` scripts automatically find the next available port. Check the terminal output for the URL.
@@ -149,7 +149,7 @@ If you prefer manual control or want to understand the process:
149149
- **Packages not found after restart:** Ensure `renv` is activated (opening `article-template.Rproj` usually does this) and run `renv::restore()` if needed.
150150
- **RStudio settings not persisting:** Ensure the `docker/cache` directory exists and has the correct permissions.
151151

152-
## Publishing Your Article {#publishing-your-article}
152+
## Publishing Your Article
153153

154154
This template is configured for easy publication on GitHub Pages using GitHub Actions.
155155

@@ -172,15 +172,15 @@ This template is configured for easy publication on GitHub Pages using GitHub Ac
172172
5. **View Your Site:**
173173
- After the workflow completes successfully, your site will be available at `https://<your-github-username>.github.io/<your-repo-name>/`.
174174

175-
## Important Notes {#important-notes}
175+
## Important Notes
176176

177177
- **Project Structure:** The main narrative files (`.qmd`) and configuration (`_quarto.yml`, `references.bib`, etc.) are in the **root** of the repository. Docker mounts this root directory to `/home/rstudio/project` inside the container.
178178
- **Docker Context:** The `docker-compose.yml` uses `..` (the project root) as the build context, allowing the Dockerfile to access files like `renv.lock`.
179179
- **renv:** This template relies heavily on `renv` for reproducibility. Familiarize yourself with its basic usage (`snapshot`, `restore`).
180180
- **Git Integration:** While the Docker environment provides isolation, you should still use Git locally on your host machine for version control of your project files.
181181
- **Administrative Files:** The `Adm/` folder is intended for administrative files and is ignored by Git (via `.gitignore`) and not published to GitHub Pages.
182182

183-
## Citation {#citation}
183+
## Citation
184184

185185
If you use this template, please cite it as:
186186

@@ -208,6 +208,6 @@ Limongi, R., & Rogers, P. (2025). Open Science in Three Acts: Foundations, Pract
208208

209209
Limongi, R., & Rogers, P. (2025). Open Science in Three Acts: Foundations, Practice, and Implementation - First Act. *BAR - Brazilian Administration Review*, *22*(1), e250079. <https://doi.org/10.1590/1807-7692bar2025250079>
210210

211-
## License {#license}
211+
## License
212212

213213
This project is licensed under the Creative Commons Attribution-NonCommercial 4.0 International License - see the [LICENSE](LICENSE) file for details.

_quarto.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ resources: # https://quarto.org/docs/projects/quarto-projects.html#project-resou
1212
- Output/
1313
- Scripts/
1414
execute: # https://quarto.org/docs/computations/execution-options.html
15+
freeze: auto # Automatically manage code execution based on changes.
1516
warning: false # Prevent R code chunk warnings from appearing in the output.
1617
book: # https://quarto.org/docs/books/index.html
1718
google-analytics: "G-2MWSHLX73Q" # replace with your Google Analytics tracking ID or remove this line

0 commit comments

Comments
 (0)