|
1 | 1 | # learn.scientific-python.org |
| 2 | + |
| 3 | +Source for [learn.scientific-python.org](https://learn.scientific-python.org), |
| 4 | +built with [MyST-MD](https://mystmd.org/) (the `mystmd` CLI). |
| 5 | + |
| 6 | +## Layout |
| 7 | + |
| 8 | +- `content/` — the MyST source project (`myst.yml` lives here). This is the |
| 9 | + main site. |
| 10 | +- `external-content/cookie/` — the [cookie](https://github.com/scientific-python/cookie) |
| 11 | + submodule, a separate MyST site. Its build is overlaid at `/development/`. |
| 12 | +- `public/` — build output. The merged, deployable static site (main + |
| 13 | + cookie). Written by `make html-all`; published by Netlify. |
| 14 | + |
| 15 | +## Prerequisites |
| 16 | + |
| 17 | +- **mystmd** — the `myst` CLI. See the |
| 18 | + [MyST install guide](https://mystmd.org/guide/quickstart). |
| 19 | +- **Node** — the cookie overlay builds via `npx mystmd`, so a full build needs |
| 20 | + Node available. |
| 21 | +- **git** — the cookie content is a submodule; `make prepare` initializes it. |
| 22 | + |
| 23 | +## Local development |
| 24 | + |
| 25 | +| Command | What it does | |
| 26 | +| ------------------ | ----------------------------------------------------------------------- | |
| 27 | +| `make serve` | Live-reload dev server for the **main site only**, at `localhost:3000`. | |
| 28 | +| `make html` | Build the main site to `content/_build/html/`. | |
| 29 | +| `make html-all` | Build main + cookie, merged into `public/`. | |
| 30 | +| `make build-serve` | Run `html-all`, then serve the full merged site at `localhost:3000`. | |
| 31 | +| `make clean` | Remove build output (`content/_build`, `public/`). | |
| 32 | + |
| 33 | +**Previewing `/development/` (cookie) locally:** `make serve` (and `myst start`) |
| 34 | +serve `content/` only — the cookie overlay is **not** visible there. To preview |
| 35 | +the full site, including `/development/`, use `make build-serve`. It is a static |
| 36 | +build (no live reload); rerun it after edits. |
| 37 | + |
| 38 | +## Decisions |
| 39 | + |
| 40 | +Architecture decisions are recorded in |
| 41 | +[`docs/decisions/`](docs/decisions/). See |
| 42 | +[`0001-myst-migration/`](docs/decisions/0001-myst-migration/) for the |
| 43 | +Hugo → MyST migration. |
0 commit comments