Hi everyone,
I just wanted to share a Nimrod program I made with the community:
https://h3rald.com/articles/hastyscribe/
It's a tool that generates standalone HTML documents (embedding stylesheets, fonts, images via data URI) by compiling an markdown file.
I used the Discount library to parse markdown (mainly because it provides some key features I need, like class blocks) which gets statically compiled when the program is compiled:
nimrod c -l:-lmarkdown -l:-L$PWD/vendor hastyscribe.nim
Hope it can be useful to someone :)
Now the questions: I'd like to add it to babel (probably a binary package at this point, but it could be used as a library as well)
This could be managed via a simple build script I guess. Any pointers on how I can configure the .babel file to accomplish this?
Hello!
Great job with the article and with hastyscribe.
how do I manage the flags to statically link the libmarkdown.a library (which in the example above is included in the vendor folder?)
You can put them in a hastyscribe.nimrod.cfg file:
-l:-lmarkdown
-l:-L./vendor
or something like that may work.
is there any way to have it build Discount into libmarkdown.a? Or do I have to distribute pre-built libraries?
Unfortunately Babel doesn't support that yet so you will need to distribute the library binaries.
I see, thanks a lot!
So let's say I am going to distribute libmarkdown.a -- I'd like to distribute at least two binaries, one working on Windows and one on OSX... Is there any way to accomplish that?
FYI, I see a bunch of [X] characters in the hero section at https://h3rald.com/hastyscribe/ eg: A sim[X]ple, self-con[X]tained, ...
Using Chrome on Mac.