tmccarthy / github-pr-language-detection

Tool that uses github-linguist to detect the language on every PR raised against a repository

Version Matrix


CircleCI Maven Central

A utility for detecting the programming languages used in pull requests against a GitHub repository.

Requires that github-linguist is installed and available on the PATH (see instructions).


Running on the command line

The project is configured using a json file of the following format:

  "gitHubConfiguration": {
    "credentials": {
      "username": "",
      "personalAccessToken": "<personal access token>"
    "instance": ""
  "repositoryToScan": "tmccarthy/github-pr-language-detection",
  "performance": {
    "checkoutsPerMinute": 16,
    "maxConcurrent": 2,
    "checkoutTimeout": "PT10S",
    "languageCheckTimeout": "PT30S"
  "reportConfig": {
    "output": "output.csv",
    "timeZone": "Australia/Melbourne",
    "languagesToIgnoreIfPossible": [

Provide the path to the config file to the cli/run SBT task:

./sbt "cli/run runconfig.json"

Use as a library

Add the following to your build.sbt file:

libraryDependencies += "" %% "github-pr-language-detection-lib" % "0.0.2"