Add path resolution for directives (#7)

This commit is contained in:
Jared Dillard
2025-05-16 17:30:02 -07:00
committed by GitHub
parent 2ca3052a2c
commit 94a82dc68b
4 changed files with 414 additions and 9 deletions
+10 -2
View File
@@ -38,10 +38,18 @@ extensions = [
- **Default**: `None` (no limit)
- **Description**: Sets a maximum line count for `llms_txt_filename`. If exceeded, the file is skipped and a warning is shown, but the build still completes.
### `llms_txt_directives`
- **Type**: list of strings
- **Default**: `[]` (empty list)
- **Description**: List of custom directive names to process for path resolution.
## Features
- Automatically add content from `.. include::` directives
- Automatically add content from `include` directives
- Resolves relative paths in directives like `image` and `figure` to use full paths
- Ability to add list of custom directives with `llms_txt_directives`
- Optionally, prepend a base URL using Sphinx's `html_baseurl`
## License