Re:Show HN: Gutenberg – A static site engine as a single exe...
by piranha on Thursday October 19, 2017 @11:08PM
(#15513301)
I would expect lower timings, see https://github.com/piranha/gostatic/blob/master/README.md#sp...
Re:Show HN: Gutenberg – A static site engine as a single exe...
by dualogy on Friday October 20, 2017 @07:24AM
(#15514890)
In Go, sure. In Haskell, for some app use-cases (and I believe static-site-gen is one such) it takes endless patience and tweaking to reach on-par performance with let's say "systems languages". There's scenarios where Haskell's lazy-evaluation may save a running program a lot of unnecessary work theoretically, but in practice I found there's not too many, compared to any eagerly-evaluated program written by a not-a-total-newbie-programmer. Certainly not such batch text-file processing. Then you'd easily parallelize your Go program wherever it makes sense, which in Haskell I didn't do but relied on whatever magic the compiler sprinkles in (if any) via compiler-options =)
Also I'm having a rather excessive template system there!
As long as it doesn't take 20s for 20p.. or I have to manage 10-100k-page sites..
That's long! Glad I wrote my own in Haskell (and I'm a Gopher! just did it to get my feet wet in Hs) --- 92 pages in 1s (full rebuild; incremental is of course just a fraction) feels good to me now. http://github.com/metaleap/haxtatic
No CSS magic tooling though. Just don't find vanilla CSS troublesome enough yet =)
Edit: I saw you do ~10k pages in ~60s so guess we can see the Rust bonus there now --- certainly beats my extrapolated expected ~5-6k for the same time-frame. (Though I hope you were talking there about complex layouts with component-like-sub-templates / programmatic sub-renderers and date-time formatting, not just dumping-inner-markup-into-outer-markup =)