https://github.com/tmccarthy/github-pr-language-detection
Tool that uses github-linguist to detect the language on every PR raised against a repository
https://github.com/tmccarthy/github-pr-language-detection
Last synced: 3 months ago
JSON representation
Tool that uses github-linguist to detect the language on every PR raised against a repository
- Host: GitHub
- URL: https://github.com/tmccarthy/github-pr-language-detection
- Owner: tmccarthy
- License: apache-2.0
- Created: 2020-11-06T11:44:15.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2020-11-15T01:17:52.000Z (over 4 years ago)
- Last Synced: 2025-01-17T01:47:00.636Z (5 months ago)
- Language: Scala
- Size: 99.6 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# `github-pr-language-detection`
[](https://circleci.com/gh/tmccarthy/github-pr-language-detection/tree/master)
[](https://repo.maven.apache.org/maven2/au/id/tmm/github-pr-language-detection/github-pr-language-detection-lib_2.13/)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](https://github.com/github/linguist/#command-line-usage)).
## Usage
### Running on the command line
The project is configured using a json file of the following format:
```json
{
"gitHubConfiguration": {
"credentials": {
"username": "[email protected]",
"personalAccessToken": ""
},
"instance": "github.com"
},
"repositoryToScan": "tmccarthy/github-pr-language-detection",
"performance": {
"checkoutsPerMinute": 16,
"maxConcurrent": 2,
"checkoutTimeout": "PT10S",
"languageCheckTimeout": "PT30S"
},
"reportConfig": {
"output": "output.csv",
"timeZone": "Australia/Melbourne",
"languagesToIgnoreIfPossible": [
"Shell"
]
}
}
```Provide the path to the config file to the `cli/run` SBT task:
```shell
./sbt "cli/run runconfig.json"
```### Use as a library
Add the following to your `build.sbt` file:
```scala
libraryDependencies += "au.id.tmm.github-pr-language-detection" %% "github-pr-language-detection-lib" % "0.0.2"
```