Carbon: ANSI escape code support

Created on 21 May 2020  ·  2Comments  ·  Source: carbon-app/carbon

I maintain various command-line tools that produce coloured output with ANSI escape codes. Every time I change the output format, I manually update various terminal screenshots on the project READMEs. I've been looking into using carbon to automate this process (and produce much nicer screenshots!).

This may be considered outside the scope for carbon, but it'd be really great to be able to generate images of files containing arbitrary ANSI escapes (rather than doing syntax highlighting on the file). This would allow using carbon to generate screenshots of terminal interactions as well as code snippets.

What do you think?

enhancement

Most helpful comment

I'm open to supporting it!

All 2 comments

I'm open to supporting it!

@mfix22 @CraigFe Integrating something like this: https://github.com/rburns/ansi-to-html seems like the way to go.

Edit: https://www.npmjs.com/package/ansicolor might work as well.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

jgierer12 picture jgierer12  ·  5Comments

chrispetrou picture chrispetrou  ·  3Comments

sivarak picture sivarak  ·  3Comments

NSExceptional picture NSExceptional  ·  3Comments

farskid picture farskid  ·  4Comments