Titles with colons causes an error saying '... contains invalid WIN32 path characters'
SteveDunn opened this issue · 1 comments
SteveDunn commented
Hi - thankyou for sharing such a great template.
I'm converting my blog from wordpress and using your template. A lot of my titles have colons in them, like:
title: "Updated: Blah blah blah!"
When I run eleventy
from the windows command line, I get an error:
Problem writing Eleventy templates: (more in DEBUG output)
> Having trouble writing template: _site/posts/updated:-Blah-blah-blah!/index.html
`TemplateWriterWriteError` was thrown
> _site/posts/update-:-blah-blah-blah! contains invalid WIN32 path characters.
I did look at this page and tried this in elvenety.js
, but to no avail:
const slugify = require("slugify");
let opts = {
permalink: true,
permalinkClass: "direct-link",
permalinkSymbol: "#",
// this is the same function shared above
slugify: function(input) {
const options = {
replacement: "-",
remove: /[&,+()$~%.'":*?<>{}]/g,
lower: true
};
return slugify(input, options);
}
};
I don't get this issue when I use elevent-bae-blah
Any help much appreciated.
Steve
SteveDunn commented
I don't get this when Netlify builds it.