Skip to content

Commit acb4297

Browse files
committed
enh: add uvx instructions
1 parent 770f398 commit acb4297

1 file changed

Lines changed: 14 additions & 10 deletions

File tree

README.md

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ Initiatives.
2424

2525
## Contributing statement
2626

27-
2827
## How to setup
2928

3029
This repository contains the source files for the [pyOpenSci Python packaging guide](https://pyopensci.org/python-package-guide).
@@ -44,44 +43,49 @@ To build, follow these steps:
4443
1. Install `nox`
4544

4645
```console
47-
$ python -m pip install nox
46+
python -m pip install nox
4847
```
48+
4949
2. Build the documentation:
5050

5151
```console
52-
$ nox -s docs
52+
nox -s docs
5353
```
5454

5555
This should create a local environment in a `.nox` folder, build the documentation (as specified in the `noxfile.py` configuration), and the output will be in `_build/html`.
5656

5757
To build live documentation that updates when you update local files, run the following command:
5858

5959
```console
60-
$ nox -s docs-live
60+
nox -s docs-live
6161
```
6262

63+
If you are a uv user, you can also skip installing `nox` and use `uvx` instead:
64+
65+
`uvx nox -s docs-live`
66+
6367
### Building for release
6468

6569
When building for release, the docs are built multiple times for each translation,
6670
but translations are only included in the production version of the guide after some completion threshold.
6771

6872
The sphinx build environment is controlled by an environment variable `SPHINX_ENV`
6973

70-
- when `SPHINX_ENV=development` (default), sphinx assumes all languages are built,
74+
* when `SPHINX_ENV=development` (default), sphinx assumes all languages are built,
7175
and includes them in the language selector
72-
- when `SPHINX_ENV=production`, only those languages in `release_languages` (set in `conf.py`)
76+
* when `SPHINX_ENV=production`, only those languages in `release_languages` (set in `conf.py`)
7377
are built and included in the language selector.
7478

7579
Most of the time you should not need to set `SPHINX_ENV`,
7680
as it is forced by the primary nox sessions intended to be used for release or development:
7781

7882
`SPHINX_ENV=development`
79-
- `docs-live` - autobuild english
80-
- `docs-live-lang` - autobuild a single language
81-
- `docs-live-langs` - autobuild all languages
83+
* `docs-live` - autobuild english
84+
* `docs-live-lang` - autobuild a single language
85+
* `docs-live-langs` - autobuild all languages
8286

8387
`SPHINX_ENV=production`
84-
- `build-test` - build all languages for production
88+
* `build-test` - build all languages for production
8589

8690
## Contributing to this guide
8791

0 commit comments

Comments
 (0)