mirror of
https://github.com/getpelican/pelican.git
synced 2025-10-15 20:28:56 +02:00
for the --dir-cat option, also slugify category's name to avoid encoding or spaces issues or ...
This commit is contained in:
parent
f337f5067b
commit
de790b9e72
1 changed files with 1 additions and 1 deletions
|
|
@ -174,7 +174,7 @@ def fields2pelican(fields, output_path, dircat=False):
|
|||
|
||||
# option to put files in directories with categories names
|
||||
if dircat and (len(categories) == 1):
|
||||
catname = categories[0]
|
||||
catname = slugify(categories[0])
|
||||
out_filename = os.path.join(output_path, catname, filename+'.rst')
|
||||
if not os.path.isdir(os.path.join(output_path, catname)):
|
||||
os.mkdir(os.path.join(output_path, catname))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue