Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ESC[0;38;5;238;48;5;231m is not recognized #25

Closed
posativ opened this issue Mar 2, 2013 · 6 comments
Closed

ESC[0;38;5;238;48;5;231m is not recognized #25

posativ opened this issue Mar 2, 2013 · 6 comments

Comments

@posativ
Copy link
Contributor

posativ commented Mar 2, 2013

Hi,

due the lack of certain syntax highlighting in pygments, I found vimcat.sh which works as expected, but when I pipe it through ansi2html, it returns no highlighted HTML.

Bildschirmfoto 2013-03-02 um 18 12 58

less has no issues to show the colors. Although I'm currently using the fish shell, I can reproduce the behavior with the regular bash. Here's the raw output:

�[0;38;5;238;48;5;231m�[K�[0;38;5;31m. �[0;38;5;238;48;5;231m~/.config/fish/export
�[0;38;5;238;48;5;231m�[K�[0;38;5;31m. �[0;38;5;238;48;5;231m~/.config/fish/prompt
�[0;38;5;238;48;5;231m�[K�[0;38;5;31m. �[0;38;5;238;48;5;231m~/.config/fish/alias
�[0;38;5;238;48;5;231m�[K�[0;38;5;238;48;5;231m
�[0;38;5;238;48;5;231m�[K�[0;38;5;25mset�[0;38;5;238;48;5;231m �[0;38;5;238m-x�[0;38;5;238;48;5;231m CLICOLOR �[0;38;5;208m1
�[0;38;5;238;48;5;231m�[K�[0;38;5;25mset�[0;38;5;238;48;5;231m �[0;38;5;238m-x�[0;38;5;238;48;5;231m TERM xterm-256color
�[0;38;5;238;48;5;231m�[K�[0;38;5;238;48;5;231m
�[0;38;5;238;48;5;231m�[K�[0;38;5;102m# curl vulnerability, http://curl.haxx.se/docs/adv_20130206.html
�[0;38;5;238;48;5;231m�[K�[0;38;5;25mset�[0;38;5;238;48;5;231m �[0;38;5;238m-x�[0;38;5;238;48;5;231m �[0;38;5;160mCURLOPT_REDIR_PROTOCOLS�[0m=�[0;38;5;208m0
�[0;38;5;238;48;5;231m�[K�[0;38;5;25mset�[0;38;5;238;48;5;231m �[0;38;5;238m-x�[0;38;5;238;48;5;231m �[0;38;5;160mCURLOPT_PROTOCOLS�[0m=�[0;38;5;208m0�[0m

(appearantly, GitHub does not show the ESC character, so here's the actual output:
Bildschirmfoto 2013-03-02 um 18 17 03)

@hartwork
Copy link
Collaborator

Fixed by (perviously merged) commit f277f8f, please close.

@ralphbean
Copy link
Collaborator

@posativ, can you confirm?

@posativ
Copy link
Contributor Author

posativ commented Sep 27, 2013

Yup, ANSI color are now visible, but the HTML returned from --inline misses a closing bracket after each </span. But on the other hand tools like a2h (a Ruby gem) fails here as well (by producing colorization at all).

I'm fine with the current state of how ansi2html handles this and it may be an issue of vimcat.sh itself.

@posativ posativ closed this as completed Sep 27, 2013
@hartwork
Copy link
Collaborator

posativ, how can I reproduce a case where ansi2html is producing </span rather than </span>? If you still get that output, please open a new issue report with detailed instructions and be sure to mention the version (or Git commit) of ansi2html that you refer to. I'd be happy to investigate and fix it. Thanks!

@posativ
Copy link
Contributor Author

posativ commented Sep 28, 2013

Opened #36 with a -- for me -- always reproducible failure, if you need more information, let me know!

@hartwork
Copy link
Collaborator

Excellent, thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants