Skip to content

Commit 0a3f9f5

Browse files
jwbowersclaude
andcommitted
Add README.md with contributor guidelines
Includes setup instructions, file naming conventions, guide template, translation workflow, and deployment documentation. Several sections marked with TODO placeholders for future expansion. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 3ed04db commit 0a3f9f5

1 file changed

Lines changed: 186 additions & 0 deletions

File tree

README.md

Lines changed: 186 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,186 @@
1+
# EGAP Methods Website
2+
3+
This repository contains the source for the [EGAP Methods website](https://methods.egap.org), a collection of methods guides for impact evaluation, along with software tools and teaching materials.
4+
5+
## How to Contribute
6+
7+
We welcome contributions to improve existing guides, fix errors, add translations, or propose new content.
8+
9+
### Reporting Issues
10+
11+
- Use [GitHub Issues](https://github.com/egap/methodsweb/issues) to report errors, suggest improvements, or propose new guides
12+
- Please check existing issues before creating a new one
13+
14+
### Making Changes
15+
16+
1. Fork the repository
17+
2. Create a branch for your changes
18+
3. Make your edits (see sections below for guidelines)
19+
4. Test locally with `quarto preview`
20+
5. Submit a pull request with a clear description of changes
21+
22+
When you make changes to one language version, note whether corresponding changes should be made to other language versions. If you can make the change in other languages, please do so.
23+
24+
## Local Development Setup
25+
26+
### Prerequisites
27+
28+
- [Quarto](https://quarto.org/docs/get-started/) (1.3 or later)
29+
- [R](https://www.r-project.org/) (4.0 or later)
30+
- RStudio (recommended but not required)
31+
32+
### Setup Steps
33+
34+
```bash
35+
# Clone the repository
36+
git clone https://github.com/egap/methodsweb.git
37+
cd methodsweb
38+
39+
# Restore R package dependencies (renv will activate automatically)
40+
R -e "renv::restore()"
41+
42+
# Preview the site locally
43+
quarto preview
44+
```
45+
46+
The site will open in your browser with live reload enabled.
47+
48+
### Building the Full Site
49+
50+
```bash
51+
# Render all pages (outputs to _site/)
52+
quarto render
53+
54+
# Render a single guide
55+
quarto render guides/research-questions/effect-types_en.qmd
56+
```
57+
58+
## File Organization
59+
60+
### Directory Structure
61+
62+
```
63+
guides/
64+
├── analysis-procedures/ # Statistical analysis methods
65+
├── assessing-designs/ # Power, external validity
66+
├── causal-inference/ # Causal inference fundamentals
67+
├── data-collection/ # Randomization, measurement, sampling
68+
├── implementation/ # Field implementation guidance
69+
├── interpretation/ # Interpreting results
70+
├── planning/ # Pre-analysis plans, survey design
71+
└── research-questions/ # Effect types, mechanisms
72+
```
73+
74+
### File Naming Convention
75+
76+
All guide files use underscore + language code before `.qmd`:
77+
78+
- English: `guide-name_en.qmd`
79+
- Spanish: `guide-name_es.qmd`
80+
- French: `guide-name_fr.qmd`
81+
82+
Each guide also has associated files in the same directory:
83+
- `guide-name.bib` — BibTeX references
84+
- `guide-name.png` — Thumbnail image for listings
85+
86+
## Writing Guides
87+
88+
### Guide Template
89+
90+
Each guide should include YAML frontmatter:
91+
92+
```yaml
93+
---
94+
title: "10 Things to Know About [Topic]"
95+
author:
96+
- name: "Author Name"
97+
url: https://author-website.com/
98+
image: guide-name.png
99+
bibliography: guide-name.bib
100+
abstract: |
101+
A brief summary of what this guide covers and who it is for.
102+
---
103+
```
104+
105+
For translated guides, also include `sidebar:` to enable the language switcher:
106+
107+
```yaml
108+
sidebar: guide-id # Must match the id in _quarto.yml
109+
```
110+
111+
### Style Guidelines
112+
113+
<!-- TODO: Add specific writing style guidelines for EGAP methods guides -->
114+
115+
- Guides follow a "10 Things to Know" format where appropriate
116+
- Use clear, accessible language suitable for researchers and practitioners
117+
- Include concrete examples and, where helpful, R code demonstrations
118+
- Use numbered sections (`#`, `##`) for the main points
119+
- Cite sources using BibTeX references
120+
121+
### Code Chunks
122+
123+
R code chunks should generally use:
124+
125+
```
126+
{r}
127+
#| echo: true
128+
#| message: false
129+
# Your code here
130+
```
131+
132+
Code is folded by default (readers click to expand). Use `#| code-fold: false` for code that should always be visible.
133+
134+
### Cross-References
135+
136+
When linking to other guides on the site, use absolute paths:
137+
138+
```markdown
139+
See [10 Things to Know About Causal Inference](https://methods.egap.org/guides/causal-inference/causal-inference_en.html)
140+
```
141+
142+
## Translations
143+
144+
### Adding a New Translation
145+
146+
1. Copy the English version (`guide-name_en.qmd`) to a new file with the appropriate language suffix (e.g., `guide-name_es.qmd`)
147+
2. Add `sidebar: guide-id` to the YAML frontmatter (use the same id as other translations of that guide)
148+
3. Translate the content, keeping the same structure and section numbering
149+
4. Update `_quarto.yml` to add the new language to the sidebar menu if needed
150+
151+
### Translation Guidelines
152+
153+
<!-- TODO: Add specific translation guidelines -->
154+
155+
- Maintain the same document structure as the English version
156+
- Keep code chunks and their output unchanged (unless translating comments)
157+
- Translate figure captions and alt text
158+
- Keep bibliographic references unchanged
159+
160+
## Adding New Guides
161+
162+
<!-- TODO: Document the process for proposing and adding new guides -->
163+
164+
1. Open an issue to propose the new guide topic
165+
2. Once approved, create the guide following the template above
166+
3. Add a thumbnail image (PNG, approximately 800x600)
167+
4. Add the guide to the appropriate sidebar in `_quarto.yml` if it needs a language switcher
168+
5. Submit a pull request
169+
170+
## Deployment
171+
172+
The site is automatically built and deployed to GitHub Pages when changes are pushed to the `main` branch. The GitHub Actions workflow:
173+
174+
1. Sets up R and restores renv dependencies
175+
2. Installs Quarto
176+
3. Renders the site
177+
4. Publishes to the `gh-pages` branch
178+
179+
## Questions?
180+
181+
- For technical issues with the site: Open a GitHub issue
182+
- For questions about EGAP: Visit [egap.org](https://egap.org)
183+
184+
## License
185+
186+
<!-- TODO: Specify the license for this content -->

0 commit comments

Comments
 (0)