Skip to content

Commit daff591

Browse files
committed
infra: remove sphinx-autobuild, add scripts
1 parent f0513fa commit daff591

File tree

2 files changed

+10
-14
lines changed

2 files changed

+10
-14
lines changed

README.rst

+3-14
Original file line numberDiff line numberDiff line change
@@ -87,12 +87,6 @@ With nix and flakes, run:
8787
8888
nix develop -c make html
8989
90-
With nix and flakes, and to autobuild run:
91-
92-
.. code-block:: bash
93-
94-
nix develop -c sphinx-autobuild . _build/html
95-
9690
With nix and no flakes, run:
9791

9892
.. code-block:: bash
@@ -105,16 +99,11 @@ To rebuild the book everytime any ``*.rst*`` file changes do:
10599
106100
find . -name "*.rst" | entr -sc '<your-build-command-here>'
107101
108-
or use ``sphinx-autobuild``:
109-
110-
.. code-block:: bash
111-
112-
sphinx-autobuild . _build/html
113-
102+
or use the ``autobuild.sh`` script in the scripts directory:
114103

115-
You can then check the output in ``_build/html`` or load directory into whatever
104+
You can then check the output in ``result/indexhtml`` or load that directory into whatever
116105
browser you'd like:
117106

118107
.. code-block:: bash
119108
120-
firefox _build/html/index.html
109+
firefox result/html/index.html

scripts/autobuild.sh

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#!/usr/bin/env bash
2+
#
3+
4+
# after a lot of hassle this simple solution is just better then sphinx-autobuild
5+
# this is intended to be used from the root directory of the book
6+
7+
find . -name '*.rst' | entr -sc 'nix build -L --no-sandbox && $(firefox --new-tab $(pwd)/result/html/index.html)'

0 commit comments

Comments
 (0)