From 87e661c5f165e710ecd0863c6e3529d0a131da0d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Piotr=20=C5=9Aliwka?= Date: Sat, 14 Apr 2018 22:25:59 +0200 Subject: [PATCH] Support using styles from Pygments plugins (#663) `pygments.styles.STYLE_MAP` contains only styles built directly into Pygments library. To list all available styles (including styles registered by plugins), one should use `get_all_styles` generator. For respective Pygments documentation, see: http://pygments.org/docs/styles/#getting-a-list-of-available-styles --- httpie/output/formatters/colors.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/httpie/output/formatters/colors.py b/httpie/output/formatters/colors.py index 87174bf1..30970c5d 100644 --- a/httpie/output/formatters/colors.py +++ b/httpie/output/formatters/colors.py @@ -16,7 +16,7 @@ from httpie.compat import is_windows from httpie.plugins import FormatterPlugin -AVAILABLE_STYLES = set(pygments.styles.STYLE_MAP.keys()) +AVAILABLE_STYLES = set(pygments.styles.get_all_styles()) AVAILABLE_STYLES.add('solarized') # This is the native style provided by the terminal emulator color scheme