💾 Archived View for bbs.geminispace.org › s › rust_software › 22384 captured on 2024-12-17 at 15:08:48. Gemini links have been rewritten to link to archived content

View Raw

More Information

-=-=-=-=-=-=-

I have old dream to implement code syntax highlight (for gemtext) - is any crate you could advice for these needs? Also, looking for ANSI -> RGB conversion crate (for terminal colors emulation)

Posted in: s/rust_software

👻 ps

Dec 02 · 2 weeks ago

3 Comments ↓

🚀 stack · Dec 02 at 15:09:

Gemtext syntax us pretty trivial... Why not just parse the first few chars yourself?

Not using too many libraries is good for the soul.

🍀 gritty · Dec 02 at 23:46:

I had a similar idea but more along the lines of a pastebin for gemni. could upload useful cgi scripts

👻 ps [OP] · Dec 03 at 01:45:

Thanks, found (by recommendation) and already integrated this crate:

— https://github.com/trishume/syntect

it's simply as maybe connect JS plugin, now have another deals with extensions detection, etc :)

finally have this feature, and some tutorials in geminispace looks much better, even integration pretty raw yet