Skip to content

Commit 17c9884

Browse files
Don't use underscores in slugs (#12)
1 parent 2e0220b commit 17c9884

File tree

2 files changed

+1
-1
lines changed

2 files changed

+1
-1
lines changed
File renamed without changes.

pelicanconf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ def sponsors(preprocessor: Preprocessor, tag: str, markup: str) -> str:
7373
INDEX_SAVE_AS = "news/index.html"
7474
# Pages we use prefix in order to split the menu between projects and general links.
7575
# News we set the default tag to the subdirectory. This can be overriden by Tags: header if multiple tags are wanted.
76-
PATH_METADATA = r"((pages/(?P<prefix>([^/]+/)|))|(news/(?P<tags>[^/]+)/(?P<date>\d{4}-\d{2}-\d{2})_))(?P<slug>.*)\.md"
76+
PATH_METADATA = r"((pages/(?P<prefix>([^/]+/)|))|(news/(?P<tags>[^/]+)/(?P<date>\d{4}-\d{2}-\d{2})_))(?P<slug>[^_]+)\.md"
7777
PAGE_URL = "{prefix}{slug}/"
7878
PAGE_SAVE_AS = "{prefix}{slug}/index.html"
7979
# We use tags as categories, so we can occasionally put something under multiple categories.

0 commit comments

Comments
 (0)