You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+8-8Lines changed: 8 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,23 +18,23 @@ When you make a pull request, pre-commit and build will run automatically, and f
18
18
19
19
## Installing the development environment locally
20
20
21
-
You will need installations of Python 3.10 and [**uv**](https://docs.astral.sh/uv/). **uv** can be used to install certain distributions of Python through the `uv python install 3.10` command but you can use other Python installations.
21
+
You will need installations of Python 3.10 and [**uv**](https://docs.astral.sh/uv/). **uv** can be used to install certain distributions of Python through the `uv python install 3.12` command but you can use other Python installations.
22
22
23
23
Clone this repository.
24
24
25
25
To install the development environment, run `uv sync` from the project root. This should create a `.venv/` directory with the Python4DS environment in it. You can check that the environment has been installed by running `uv run python -V` in the project root directory.
26
26
27
27
## Building the book
28
28
29
-
The book is compiled from source markdown and Jupyter notebook files [**jupyter-book**](https://jupyterbook.org/en/stable/) package.
29
+
The book is compiled from source markdown and Jupyter notebook files using [**Quarto**](https://quarto.org/). You will need Quarto installed on your system — see the [Quarto installation guide](https://quarto.org/docs/get-started/).
30
30
31
31
To build the book, run
32
32
33
33
```bash
34
-
uv run jupyter-book build .
34
+
uv run quarto render --execute
35
35
```
36
36
37
-
Once this command is run, you should be able to look at the HTML files for the book locally on your computer. They will be in `_build`. The project is configured to stop the build if any errors are encountered. This is a frequent occurrence! You'll need to look at the logs to work out what might have gone wrong.
37
+
Once this command is run, you should be able to look at the HTML files for the book locally on your computer. They will be in `_book`. The `freeze: auto` setting means only notebooks whose source has changed will be re-executed on subsequent builds.
38
38
39
39
## Uploading the book
40
40
@@ -46,10 +46,10 @@ This repo is configured such that new versions automatically build and upload th
46
46
47
47
You shouldn't need to upload the book if you are a regular contributor. There are times when you might need to as an admin, but normally the book will be updated automatically upon release of a new version.
48
48
49
-
See [here](https://jupyterbook.org/publish/gh-pages.html) for how to upload revised HTML files, but the key command is
49
+
First build the book, then publish with:
50
50
51
51
```bash
52
-
uv run ghp-import -n -p -f _build/html
52
+
uv run quarto publish gh-pages --no-render --no-browser
53
53
```
54
54
55
55
## Code hygiene
@@ -78,7 +78,7 @@ on your staged files. Ensure pre-commit reports all tests as having passed befor
78
78
79
79
## Running and developing in a Docker container
80
80
81
-
There is a Dockerfile associated with this project. Pre-reqs
81
+
There is a Dockerfile associated with this project.
82
82
To use it:
83
83
84
84
1. Pre-reqs: docker installed, VS Code installed, VS Code docker and Remote Explorer extensions installed.
@@ -90,5 +90,5 @@ There is a Dockerfile associated with this project. Pre-reqs
90
90
If you wish to copy any files (eg the built HTML files) back to your local machine to check them, use
0 commit comments