A regex-based programming language.
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
Examples Add new example programs and explanations/tutorial Jan 22, 2018
Retina Remove old example programs Jan 21, 2018
.gitignore Remove old example programs Jan 21, 2018
CHANGELOG.md Update changelog Jan 18, 2018
LICENSE.md Create LICENSE.md Feb 13, 2015
README.md Update README.md Jan 30, 2018
Retina.exe Remove old example programs Jan 21, 2018



Retina is a regex-based recreational programming language. Every program works by reading a (finite) string from standard input, transforming it via a series of regex operations (e.g. counting matches, filtering lines, and most of all substituting). Retina was built on top of .NET's regex engine, but provides its own, more powerful substitution syntax.

Retina was mainly developed for code golf which may explain its very terse configuration syntax and some weird design decisions.

Running Retina

The easiest way to try out Retina is to use it right in your browser at Try It Online!

There is an up-to-date .NET binary of Retina in the root directory of the repository. Alternatively, you can build it yourself from the C# sources. The code requires .NET 4.5. I do not regularly test Retina with Mono, but previous versions have worked without problems.

Source files can simply be passed as command-line arguments. For details of ways to invoke Retina see the docs.

How does it work?

Full documentation of the language can be found in the Wiki. For a (hopefully) more accessible introduction to the language's basic features see the annotated example programs. It might also be worth having a look at the changelog.