Skip to content

REPO / All courses: duplicate content accross courses #79

@eemilhaa

Description

@eemilhaa

Issue

There's unnecessary duplication accross the course materials. For example, QGIS basics such as connecting to a WMS are covered very similarly in multiple courses.

When a duplicated exercise is updated, ideally the changes should be reflected in all the places that use said exercise. Currently this is manual and prone to be forgotten: It requires the maintainer to 1. know that the material is duplicated, 2. know all of the places where it is duplicated.

Solutions

To fix this, we'd need to include either files or the rmarkdown contents of files accross different courses.

  • The file approach could be done by symlinking the duplicated exercise .Rmd file wherever it is needed. This is probably not enough: for example, exercise numbering gets messed up if the exercise is a different number accross courses.

  • We can also include rmarkdown directly between files. This would overcome the numbering issue, as we can include only the exercise content. For example:

# Harjoitus 2

whatever is specific to the exercise in this course

Include the rest of the content from here:

```{r, child='./path/to/shared_exercise.Rmd'}

Having quickly tested this, including contents from other rmarkdown files this way seems to work with our course material setup (render.sh).

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions