Forrest logo
back to the pygmentize tool

pygmentize:tldr:72ea3

pygmentize: List available lexers (processors for input languages).
$ pygmentize -L lexers
try on your machine

The command "pygmentize -L lexers" is used to display a list of all the available syntax highlighters (also known as lexers) that can be used with the Pygments library.

Pygments is a syntax highlighting library in Python that can be used to highlight code in various programming languages and document formats. It supports a wide range of languages and formats including Python, HTML, CSS, JavaScript, Java, C++, Markdown, JSON, XML, and many more.

The command "pygmentize" is the main command-line interface for Pygments. The option "-L" specifies that we want to list the available lexers. Lexers are responsible for tokenizing the input code or document into individual elements such as keywords, operators, comments, and literals.

By running the command "pygmentize -L lexers", you will get a comprehensive list of all the lexers Pygments currently supports. This information can be useful when you want to determine which lexer to use for a specific programming language or document format when using Pygments in your projects.

This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the pygmentize tool