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: doc/README.md
+14-27Lines changed: 14 additions & 27 deletions
Original file line number
Diff line number
Diff line change
@@ -11,48 +11,34 @@ http://cabal.readthedocs.io/
11
11
12
12
### How to build it
13
13
14
-
Building the documentation requires Python 3and PIP. Run the following command either from the root of the cabal repository or from the `docs/` subdirectory:
14
+
Building the documentation requires Python 3, PIP, and `pip-tools` (see the second note below for how to install it). Run the following command either from the root of the cabal repository or from the `docs/` subdirectory:
15
15
16
16
```console
17
-
make users-guide
17
+
> make users-guide
18
18
```
19
19
20
20
Note: Python on Mac OS X dislikes `LC_CTYPE=UTF-8`, so unset the variable
21
21
and instead set `LC_ALL=en_US.UTF-8`.
22
22
23
-
### How to update dependencies
24
-
25
-
Once in a while you need to update Python dependencies (for instance,
26
-
when Dependabot alerts about possible security flaw). The list of
27
-
transitive dependencies (`requirements.txt`) is generated from the
28
-
list of direct dependencies in `requirements.in`. To perform the
29
-
generation step run
23
+
Note: You can use a vendor package for `pip-tools`, or run
30
24
31
-
```console
32
-
> make users-guide-requirements
25
+
```console
26
+
> pip install pip-tools
33
27
```
34
28
35
-
either from the root of the cabal repository or from the `docs/` subdirectory.
29
+
Make sure the installation directory (often `$HOME/.local/bin`) is on your `$PATH`.
36
30
37
-
Note that generating `requirements.txt` is sensitive to the Python version.
38
-
The version currently used is stamped at the top of `requirements.txt`.
39
-
Normally, we would expect the same version of Python to be used for
40
-
regeneration. An easy way to enforce a particular version is to perform
41
-
regeneration in a Docker container, e.g. (from the root of repository):
31
+
### How to update dependencies
32
+
33
+
The list of transitive dependencies (`requirements.txt`) is generated from the list of direct dependencies in `requirements.in`. To perform the generation step, run
42
34
43
35
```console
44
-
> docker run -itv $PWD:/cabal python:3.10-alpine sh
45
-
...
46
-
# apk add make
47
-
...
48
-
# cd cabal
49
-
# make users-guide-requirements
36
+
> make users-guide-requirements
50
37
```
51
38
52
-
One way to make sure the dependencies are reasonably up to date
53
-
is to remove `requirements.txt` and regenerate it as described
54
-
above. But in some cases you may have to add a bound manually
55
-
to `requirements.in`, e.g. `requests >= 2.31.0`.
39
+
either from the root of the cabal repository or from the `docs/` subdirectory. You will need to do this before building documentation the first time, but should only need to repeat it after a `git clean` or if the dependencies in `requirements.in` change.
40
+
41
+
In some cases, you may have to add a bound manually to `requirements.in`, e.g. `requests >= 2.31.0`.
56
42
57
43
### Gitpod workflow
58
44
@@ -70,6 +56,7 @@ Make your edits, rebuild the guide and refresh the browser to preview the
70
56
changes. When happy, commit your changes with git in the included terminal.
71
57
72
58
### Caveats, for newcomers to RST from MD
59
+
73
60
RST does not allow you to skip section levels when nesting, like MD
0 commit comments