parent
8a6d3d42ec
commit
a0da580f87
|
@ -37,6 +37,7 @@ sections up to the index to be used with the `get_section` Tera function
|
|||
- Ensure content directory exists before rendering aliases
|
||||
- Do not include drafts in pagination
|
||||
- Pages filenames starting by a date will now use that date as page date if there isn't one defined in frontmatter
|
||||
- Accept markdown files starting with BOM
|
||||
|
||||
## 0.4.2 (2018-09-03)
|
||||
|
||||
|
|
|
@ -39,6 +39,11 @@ pub fn read_file(path: &Path) -> Result<String> {
|
|||
.chain_err(|| format!("Failed to open '{:?}'", path.display()))?
|
||||
.read_to_string(&mut content)?;
|
||||
|
||||
// Remove utf-8 BOM if any.
|
||||
if content.starts_with("\u{feff}") {
|
||||
content.drain(..3);
|
||||
}
|
||||
|
||||
Ok(content)
|
||||
}
|
||||
|
||||
|
|
|
@ -1,2 +1,4 @@
|
|||
+++
|
||||
+++
|
||||
+++
|
||||
|
||||
This file starts with a UTF-8 BOM and should be loaded
|
||||
|
|
Loading…
Reference in a new issue