Files
sphinx/tests
Chris Sewell bc1a5c5c88 [autogen] Add --remove-old option (#12456)
A common "gotcha" of re-running `sphinx-autogen`, is that if there are changes it will not remove old files, leading to build errors for files not in a `toctree`

This commit introduces a `--remove-old` option to remove these files.

Note, a key detail here is that we don't want to simply clear the directory before running `sphinx-autogen`,
since this would lead to all files having a new `mtime`,
and then `sphinx-build` would rebuild all of them even if they have not changed.
So we must first collect the list of all correct files, then remove any not in the list.
2024-06-21 19:29:46 +02:00
..
2024-01-18 00:52:25 +00:00
2020-11-20 19:43:02 +01:00
2022-02-20 03:13:45 +00:00