In case it's useful for future readers, here are some samples: https://github.com/titzer/virgil/tree/master/doc/tutorial/ex...
This is an example from itzer/virgil [1]:
def fib(i: int) -> int {
if (i <= 1) return 1;
return fib(i - 1) + fib(i - 2);
}
And an example from munificent/vigil [2]: def fib(n):
if n < 2:
result = n
else:
result = fib(n - 1) + fib(n - 2)
swear result >= 0
return result
[1] https://github.com/titzer/virgil/blob/master/doc/tutorial/Me...Once you have that, you can post your docs in GitHub Pages (or something like Netlify[4] or Cloudflare[5]), they both can run a command to build your website (from markdown to html) every time you push to a branch, and then serve the HTML generated as a static site.
Before this though, your language seems similar enough to others (maybe Java or C#?) that if you tell the converter to use those languages, you'll get decent enough highlighting. I did this to highlight Zig code before it became supported by telling the converter it was typescript code (coincidentally, many keywords seem to have aligned well enough)!
[1] https://github.com/Depado/bfchroma/
[2] https://github.com/alecthomas/chroma#supported-languages
[3] https://pygments.org/docs/lexerdevelopment/
[4] https://www.netlify.com/blog/2016/10/27/a-step-by-step-guide...