Gradle plugin that allows easy integration with the infer static analyzer.
Groovy Java
Latest commit 7ea780b Jan 27, 2017 @tonycosentini tonycosentini committed on GitHub Merge pull request #29 from Ilya-Gh/add_plugin_to_sample_dependency
Add plugin to sample dependencies
Permalink
Failed to load latest commit information.
gradle
infer-plugin
infer-sample Add plugin to samples dependencies Jan 24, 2017
.gitignore
LICENSE Updating liscence. May 13, 2016
README.md Updating readme to 0.7.4 Nov 3, 2016
build.gradle Bump gradle-2.13-all to 3.1 Nov 2, 2016
gradle.properties Add plugin to samples dependencies Jan 24, 2017
gradlew Commiting infer-plugin. May 10, 2016
settings.gradle Commiting infer-plugin. May 10, 2016

README.md

Infer Gradle Plugin

This Gradle plug-in creates tasks to run Infer on Android and Java projects.

Integration

To use this plug-in, you must have Infer installed.

Add the plug-in dependency and apply it in your project's build.gradle:

buildscript {
    repositories {
        mavenCentral()
    }
    dependencies {
        ...
        classpath "com.uber:infer-plugin:0.7.4"
    }
}

Applying the Plugin

Android

apply plugin: 'com.android.application'
apply plugin: 'com.uber.infer.android'

Java

apply plugin: 'java'
apply plugin: 'com.uber.infer.java'

Including and Excluding

In the build.gradle of the project that applies the plugin:

inferPlugin {
    infer {
        include = project.files("<PATH_TO_INCLUDE>")
        exclude = project.files("<PATH_TO_EXCLUDE>")
    }
    eradicate {
        include = project.files("<PATH_TO_INCLUDE>")
        exclude = project.files("<PATH_TO_EXCLUDE>")
    }
}

Tasks

  • infer - runs Infer's standard analyzer.
  • eradicate - runs Infer's Eradicate analyzer.

For Android projects, the plug-in will create a task for each build variant in your application or library (for example, debug and release).

  • inferVaraint - runs Infer's standard analyzer.
  • eradicateVariant - runs Infer's Eradicate analyzer.

For a specific list of tasks available on your project, run Gradle's tasks command.

Contributors

We'd love for you to contribute to our open source projects. Before we can accept your contributions, we kindly ask you to sign our Uber Contributor License Agreement.

  • If you find a bug, open an issue or submit a fix via a pull request.
  • If you have a feature request, open an issue or submit an implementation via a pull request
  • If you want to contribute, submit a pull request.