I'm currently looking for a way on macOS to create an ebook (PDF, ePub, and Mobi) using markdown syntax, but I can't find a good app/service for that. I tried using the template feature in iA Writer, but it does not support adding a cover image on the first page of the generated PDF. This app also doesn't support exporting to ePub or Mobi formats.
I'm actually a developer, and I can create an app/script that lets me convert markdown to an ebook with any formatting/styling I want, but I'm trying to avoid re-inventing the wheel. So please let me know if you know any good software to accomplish that, otherwise I'll do it myself (and share it with you if you're interested).