Skip to content

Commit adeccf6

Browse files
authored
docs: point contributors at geolibre-assets for images and demos (#1768)
* docs: point contributors at the geolibre-assets repo for binaries Screenshots, GIFs, and sample datasets were being committed straight into docs/assets, which permanently enlarges the clone for everyone since Git history keeps them forever. Add a Documentation subsection directing contributors to opengeos/geolibre-assets instead, with the repo-path to assets.geolibre.app URL mapping, the per-directory conventions, the format preferences, and the caveat that published paths are effectively permanent. * Address CodeRabbit review feedback - Spell out the hosting contract: geolibre-assets is a plain static host (any file type), publishes from `main` via GitHub Pages under its single hostname assets.geolibre.app, usually within a minute, with GitHub's 100 MB per-file limit. - Note that some existing pages point at other GeoLibre-operated hosts (data.geolibre.app, files.opengeos.org); those URLs keep working and need no rewriting, but new assets go to geolibre-assets since that is the one contributors can open a PR against. - State explicitly that the published assets.geolibre.app URL is the exception to the "link to files outside docs/ with a full GitHub URL" rule above. * Address Claude review feedback - Align the asset-path table's pipe columns; all five rows are now the same width. No pre-commit hook formats Markdown, so this would not have been fixed automatically. - Soften the closing sentence, which asserted a stricter invariant than the repo satisfies: docs/assets/ also holds an orphaned geolibre-app.png that nothing references. It now names the icon as the one live file and says an unreferenced file there is a leftover, not a precedent.
1 parent 475b37e commit adeccf6

1 file changed

Lines changed: 50 additions & 0 deletions

File tree

docs/contributing.md

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -197,6 +197,56 @@ links and pages left out of the navigation fail the build. Link to other docs
197197
pages with a relative path (for example `architecture.md`), and link to files
198198
outside `docs/` with a full GitHub URL.
199199

200+
### Images, demos, and sample data
201+
202+
**Do not commit screenshots, GIFs, videos, or sample datasets to this
203+
repository.** Binaries are never really deleted from Git history, so every one
204+
of them permanently enlarges the clone for everyone, including CI.
205+
206+
Put them in [opengeos/geolibre-assets](https://github.com/opengeos/geolibre-assets)
207+
instead. It is a plain static host, so any file type works. Anything pushed to
208+
that repository's `main` branch is published by GitHub Pages at the matching
209+
path under its one hostname, <https://assets.geolibre.app>, usually within a
210+
minute:
211+
212+
| Repository path | Published URL |
213+
| ---------------------- | -------------------------------------------------- |
214+
| `images/my-panel.webp` | `https://assets.geolibre.app/images/my-panel.webp` |
215+
| `demos/my-demo.gif` | `https://assets.geolibre.app/demos/my-demo.gif` |
216+
| `data/sample.parquet` | `https://assets.geolibre.app/data/sample.parquet` |
217+
218+
Then reference the published URL from your Markdown:
219+
220+
```markdown
221+
![Raster style panel](https://assets.geolibre.app/images/raster-style-panel.webp)
222+
```
223+
224+
This is the one exception to the "link to files outside `docs/` with a full
225+
GitHub URL" rule above: an asset in `geolibre-assets` is referenced by its
226+
published `assets.geolibre.app` URL, never by a GitHub blob or raw URL.
227+
228+
A few things worth knowing:
229+
230+
- Use `images/` for stills, `demos/` for animations and screen recordings,
231+
`data/` for sample datasets, and `styles/` or `fonts/` for map resources.
232+
- Prefer **WebP** or AVIF for stills, and PMTiles or GeoParquet for data. The
233+
screenshots on this site are WebP.
234+
- Keep individual files under 100 MB, GitHub's hard limit.
235+
- Published paths are effectively permanent. Renaming or deleting a file breaks
236+
every page already pointing at it, so pick the name once.
237+
- Assets are served with permissive CORS, so the app can fetch them
238+
cross-origin.
239+
240+
Some existing pages point at other GeoLibre-operated hosts, mainly
241+
`data.geolibre.app` and `files.opengeos.org`. Those URLs keep working and do not
242+
need rewriting; `geolibre-assets` is simply the one you can open a pull request
243+
against, so send new assets there.
244+
245+
The only images that belong in this repository are the site chrome under
246+
`docs/assets/` — currently just the icon `mkdocs.yml` uses for the logo and
247+
favicon. Do not add to that directory; if you find something there that nothing
248+
references, it is a leftover, not a precedent.
249+
200250
## Plugins and extensions
201251

202252
GeoLibre supports external plugins loaded from a zip, a local directory, or a

0 commit comments

Comments
 (0)