kevboh / longform

A plugin for Obsidian that helps you write and edit novels, screenplays, and other long projects.
Other
662 stars 31 forks source link

Compile Step: Retain/Insert some YAML for Pandoc export #179

Open kelleyskovron opened 1 year ago

kelleyskovron commented 1 year ago

What should this step do?

I use Pandoc to export into docx, which utilizes the title, subtitle, and author YAML tags to automatically create frontmatter for me. The only way I seem to be able to retain that in longform during compile is if I remove both Remove Frontmatter step, and the Prepend Title step, because otherwise the YAML ends up after the first header, which Pandoc won't read as YAML. Of course that means I need to manually put header titles in for each scene file so that something shows up on compile. It would be real swell to either have a file that is exempt from all this, or adds YAML metadata like title and author in to the compiled file at the very end.

Should this step affect scenes, manuscripts, or join the two? I suppose join?

I'm excited about the possibilities of this project! I posted it on the SFWA Discord because there's definitely some authors who are Obsidian-curious, but daunted by the fiddling it currently requires to use as a manuscript writing tool. This could really give them the tools they need to break away from things like Scrivener or worse, MS Word Best of luck with this endeavor! I'll be keeping an eye on it!

kevboh commented 1 year ago

because otherwise the YAML ends up after the first header

This is a good point and is a bug that should be fixed. The rest is just a good suggestion; I lean toward an "Add frontmatter" step, personally.