kevinah95 / KDriller

Kotlin Framework to analyse Git repositories

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

KDriller

GitHub license Maven Central Sonatype Nexus (Snapshots) Kotlin FOSSA Status

KDriller is a Kotlin framework that helps developers in analyzing Git repositories. With KDriller you can easily extract information about commits, developers, modified files, diffs, and source code.

About this repository

This project is a kotlin implementation of PyDriller by Davide Spadini, originally from PyDriller.

Quick usage

import kdriller

val pathToRepo = listOf("https://github.com/ishepard/pydriller.git")
for(commit in Repository(pathToRepo).traverseCommits()){
        println(commit.hash)
        println(commit.msg)
        println(commit.author.name)
    }

Installation

with Gradle

repositories {
    mavenCentral()
}

dependencies {
    implementation("com.github.kevinah95:kdriller:[version]")
}

How to contribute

First clone the repository:

git clone https://github.com/kevinah95/kdriller.git
cd kdriller

(Important) I tend to not accept Pull Requests without tests, so:

  • unzip the test-repos.zip zip file in src/commonTest/resources/test-repos.zip.
  • inside are many "small repositories" that were manually created to test KDriller. Use one of your choice to test your feature (check the existing tests for inspiration)
  • if none is suitable for testing your feature, create a new one. Be careful: if you create a new one, do not forget to upload a new zip file test-repos.zip that includes your new repository, otherwise the tests will fail.

To run the tests use gradle.

License

FOSSA Status

About

Kotlin Framework to analyse Git repositories

License:Apache License 2.0


Languages

Language:Kotlin 100.0%