From 9775c281f77525e09be27aec67d3ef71da0247ad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matth=C3=A4us=20G=2E=20Chajdas?= Date: Wed, 29 Dec 2021 16:39:03 +0100 Subject: Provide an accurate count instead of "over 500". --- doc/conf.py | 1 + doc/index.rst | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) (limited to 'doc') diff --git a/doc/conf.py b/doc/conf.py index c217d659..70f60559 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -224,6 +224,7 @@ man_pages = [ # Example configuration for intersphinx: refer to the Python standard library. #intersphinx_mapping = {'http://docs.python.org/': None} +rst_prolog = '.. |language_count| replace:: {}'.format(len(list(pygments.lexers.get_all_lexers()))) def pg_context(app, pagename, templatename, ctx, event_arg): ctx['demo_active'] = bool(os.environ.get('WEBSITE_BUILD')) diff --git a/doc/index.rst b/doc/index.rst index 4495943a..7b1636d5 100644 --- a/doc/index.rst +++ b/doc/index.rst @@ -5,7 +5,7 @@ This is the home of Pygments. It is a generic syntax highlighter suitable for use in code hosting, forums, wikis or other applications that need to prettify source code. Highlights are: -* a wide range of over 500 languages and other text formats is supported +* a wide range of |language_count| languages and other text formats is supported * special attention is paid to details that increase highlighting quality * support for new languages and formats are added easily; most languages use a simple regex-based lexing mechanism -- cgit v1.2.1