diff options
| author | Vladimír Vondruš <mosra@centrum.cz> | 2019-01-04 17:08:32 +0100 |
|---|---|---|
| committer | Vladimír Vondruš <mosra@centrum.cz> | 2019-01-04 17:08:32 +0100 |
| commit | 94db14e801c58eb62df9588ae663eb40bbdf2c5d (patch) | |
| tree | e22510ee3131439d32d7115c87ba08e7cf63ab47 /docs | |
| parent | b6d423d2b8799d9e6b71227cb1d5f727b206ba9e (diff) | |
| download | pelican-94db14e801c58eb62df9588ae663eb40bbdf2c5d.tar.gz | |
docs: properly show escaped chars in SLUG_REGEX_SUBSTITUTIONS.
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/settings.rst | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/docs/settings.rst b/docs/settings.rst index 640d0571..90b9e570 100644 --- a/docs/settings.rst +++ b/docs/settings.rst @@ -588,10 +588,10 @@ corresponding ``*_URL`` setting as string, while others hard-code them: ``'tags.html'``. .. data:: SLUG_REGEX_SUBSTITUTIONS = [ - (r'[^\w\s-]', ''), # remove non-alphabetical/whitespace/'-' chars - (r'(?u)\A\s*', ''), # strip leading whitespace - (r'(?u)\s*\Z', ''), # strip trailing whitespace - (r'[-\s]+', '-'), # reduce multiple whitespace or '-' to single '-' + (r'[^\\w\\s-]', ''), # remove non-alphabetical/whitespace/'-' chars + (r'(?u)\\A\\s*', ''), # strip leading whitespace + (r'(?u)\\s*\\Z', ''), # strip trailing whitespace + (r'[-\\s]+', '-'), # reduce multiple whitespace or '-' to single '-' ] Regex substitutions to make when generating slugs of articles and pages. |
