From e4cc5635c094c60f487d278eb49b9dd66a2a312c Mon Sep 17 00:00:00 2001 From: Mishig Date: Fri, 28 Oct 2022 13:49:32 +0200 Subject: [PATCH] Add redirects readme (#318) --- README.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/README.md b/README.md index 23bac6a1..ad6c027d 100644 --- a/README.md +++ b/README.md @@ -95,9 +95,11 @@ Note the use of special arguments like `pr_number` and `package` under the `with doc_folder ├── en │ ├── _toctree.yml +│ ├── _redirects.yml │ ... └── es ├── _toctree.yml + ├── _redirects.yml ... ``` @@ -109,6 +111,15 @@ doc-builder {package_name} {path_to_docs} --build_dir {build_dir} --language {la To automatically build the documentation for all languages via the GitHub Actions templates, simply provide the `languages` argument to your workflow, with a space-separated list of the languages you wish to build, e.g. `languages: en es`. +#### Redirects + +You can optionally provide `_redirects.yml` for "old links". The yml file should look like: + +```yml +how_to: getting_started +package_reference/classes: package_reference/main_classes +# old_local: new_local +``` ## Writing documentation for Hugging Face libraries