Closed pskyhx closed 2 years ago
this in the template:
tags: # โ ๏ธ check how does this output
- {{tags}}
#summary: # โ
produces this:
tags: # โ ๏ธ check how does this output
- #summary: # โ
because there are no tags.
There is a colon in the title which breaks the YAML:
failed to unmarshal YAML: yaml: mapping values are not allowed in this context
Enclosing it in quotes seems to fix.
tags still displaying wrong possibly due to my irrational love of emojis:
tags:
- mdnotes
๐-Academic-Periodicals
very weird, how the emoji gets put before the dash. If it is changed like this:
- ๐Academic-Periodicals
the way it should be, it works.
Emoji in the middle of tag causes no problem.
Leading space added to front of tag gets removed
enclosing in brackets (๐)-Academic-Periodicals
has original behaviour.
enclosing the name of the tag in double quotes in zotero has an interesting effect a suggesting maybe the emoji isn't actually the problem:
tags:
- mdnotes
zztest-tag <<<<<<
- delete-the-tag
- but-don't-delete-the-file
- how-about-๐-emojis?
- "๐-Academic-Periodicals"
addressed in 37f6a3c:
{"content":"tags: \n{{field_contents}}", "field_contents": " - {{content}}", "link_style": "no-links", "list_separator": "\n", "remove_spaces": "true"}
and in the template file, just have {{tags}}
.
The problem was not the emoji, it was the malformed json
and yaml
combo.
yaml
spec: YA-ML Ainโt Markup Language (YAMLโข) revision 1.2.2
Problem: when values are missing
---
title: "{{title}}"
title-short: "{{shortTitle}}"
originalyear: {{date}}
type: "{{itemType}}"
alias: "{{citekey}}"
lang: "{{language}}"
draft: true
date: {{accessDate}}
---
becomes in a files with minimal metadata:
---
title: "ZZZZ test fake file"
title-short: ""
originalyear: type: ""
alias: "zotero-1405"
lang: ""
draft: true
date: ---
Problems:
originalyear
squashes next line into ityaml
---
is not on own line. solution to both: trailing space at end of line after }}
retains the structure. Is trailing space in violation of yaml
? If that ended up being the case, could solve similarly to tags
above by re-integrating the whole line into the mdnotes
output. for now it looks fine.
All my test files can now pass through mdnotes
batch export without breaking hugo. :)
attempting to build