-
Notifications
You must be signed in to change notification settings - Fork 168
Closed
Labels
documentationhackathon2025Good issues for the hackathon at the Parcels anniversary event in 2025.Good issues for the hackathon at the Parcels anniversary event in 2025.v4
Description
If you want local copies of the notebooks, you can currently download them as a zip of them from our tutorials homepage https://docs.oceanparcels.org/en/latest/documentation/index.html . However:
- its unusual that someone would want to download all the notebooks (they probably just want to look at one of particular interest)
- this creating of the zip creates unnecessary complexity in the build process
A better option would be to implement something similar to what xarray has on their gallery page - an autogenerated pre-amble (specified in conf.py) of
Here these are just links (no added complexity to the build process) and has the added benefit of providing a link directly to open in Binder and try the code.
Needed changes:
- Add pre-amble (Binder link, and "download from GitHub" link)
- Note: the link should not just point to main - but should depend on the version being built. This prevents downloading the latest notebook when an old version of docs is being looked at. Create a function
_get_github_ref_for_build()which returns a GitHub reference/tag/branch name to be interpolated into the string (if "unknown" - e.g., running local - usemain). InspectingREADTHEDOCS_VERSION_TYPEandREADTHEDOCS_VERSION_NAMEenvironment variables (docs) will help here.
- Note: the link should not just point to main - but should depend on the version being built. This prevents downloading the latest notebook when an old version of docs is being looked at. Create a function
- Remove zip building workflow
Metadata
Metadata
Assignees
Labels
documentationhackathon2025Good issues for the hackathon at the Parcels anniversary event in 2025.Good issues for the hackathon at the Parcels anniversary event in 2025.v4
Type
Projects
Status
Done
Status
Done