Skip to main content

ANTLeRinator

Project description

https://img.shields.io/pypi/v/antlerinator?logo=python&logoColor=white https://img.shields.io/pypi/l/antlerinator?logo=open-source-initiative&logoColor=white https://img.shields.io/github/workflow/status/renatahodovan/antlerinator/main/master?logo=github&logoColor=white

ANTLeRinator is a Python utility package to help keeping components of ANTLR v4 in sync.

Requirements

  • Python ~= 2.7 or >= 3.5

  • pip

  • Java SE >= 7 JRE or JDK (the latter is optional)

Install

The quick way:

pip install antlerinator

Alternatively, by cloning the project and performing a local install:

pip install .

Usage

A common form of ANTLeRinator’s usage:

import antlerinator
import argparse
import subprocess

assert antlerinator.__antlr_version__ is not None

parser = argparse.ArgumentParser()
antlerinator.add_antlr_argument(parser)
args = parser.parse_args()

antlerinator.process_antlr_argument(args)

subprocess.call(['java', '-jar', args.antlr])

Should there be need for downloading the ANTLR v4 tool jar manually, a helper script is available:

antlerinator-download

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

antlerinator-1!1.0.0.tar.gz (10.3 kB view hashes)

Uploaded Source

Built Distribution

antlerinator-1!1.0.0-py2.py3-none-any.whl (7.1 kB view hashes)

Uploaded Python 2 Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page