Merge pull request #3462 from Kristinita/KiraValidPathMetadataValue

docs: Use raw string for the `PATH_METADATA` setting
This commit is contained in:
Justin Mayer 2025-04-19 12:28:16 +02:00 committed by GitHub
commit f9711fa10a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 3 additions and 3 deletions

View file

@ -118,7 +118,7 @@ How do I make my output folder structure identical to my content hierarchy?
Try these settings:: Try these settings::
USE_FOLDER_AS_CATEGORY = False USE_FOLDER_AS_CATEGORY = False
PATH_METADATA = "(?P<path_no_ext>.*)\..*" PATH_METADATA = r"(?P<path_no_ext>.*)\..*"
ARTICLE_URL = ARTICLE_SAVE_AS = PAGE_URL = PAGE_SAVE_AS = "{path_no_ext}.html" ARTICLE_URL = ARTICLE_SAVE_AS = PAGE_URL = PAGE_SAVE_AS = "{path_no_ext}.html"
How do I assign custom templates on a per-page basis? How do I assign custom templates on a per-page basis?

View file

@ -458,7 +458,7 @@ If you don't want that flexibility and instead prefer that your generated
output paths mirror your source content's filesystem path hierarchy, try the output paths mirror your source content's filesystem path hierarchy, try the
following settings:: following settings::
PATH_METADATA = '(?P<path_no_ext>.*)\..*' PATH_METADATA = r'(?P<path_no_ext>.*)\..*'
ARTICLE_URL = ARTICLE_SAVE_AS = PAGE_URL = PAGE_SAVE_AS = '{path_no_ext}.html' ARTICLE_URL = ARTICLE_SAVE_AS = PAGE_URL = PAGE_SAVE_AS = '{path_no_ext}.html'
Otherwise, you can use a variety of file metadata attributes within URL-related Otherwise, you can use a variety of file metadata attributes within URL-related

View file

@ -144,7 +144,7 @@ DEFAULT_CONFIG = {
"DEFAULT_ORPHANS": 0, "DEFAULT_ORPHANS": 0,
"DEFAULT_METADATA": {}, "DEFAULT_METADATA": {},
"FILENAME_METADATA": r"(?P<date>\d{4}-\d{2}-\d{2}).*", "FILENAME_METADATA": r"(?P<date>\d{4}-\d{2}-\d{2}).*",
"PATH_METADATA": "", "PATH_METADATA": r"",
"EXTRA_PATH_METADATA": {}, "EXTRA_PATH_METADATA": {},
"ARTICLE_PERMALINK_STRUCTURE": "", "ARTICLE_PERMALINK_STRUCTURE": "",
"TYPOGRIFY": False, "TYPOGRIFY": False,