Skip to content
This repository has been archived by the owner on Feb 11, 2022. It is now read-only.

Commit

Permalink
Merge pull request #147 from novoda/release0.7
Browse files Browse the repository at this point in the history
Prepare Release 0.7
  • Loading branch information
mr-archano authored Nov 10, 2018
2 parents 0f60fbf + ab3c47e commit b0a478c
Show file tree
Hide file tree
Showing 10 changed files with 40 additions and 36 deletions.
12 changes: 11 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,20 @@
Change Log
==========

[Version 0.7](https://github.com/novoda/gradle-static-analysis-plugin/releases/tag/v0.7)
--------------------------

- Fix Detekt RC9.x and RC10 integrations [PR#144](https://github.com/novoda/gradle-static-analysis-plugin/pull/144)
- Fix Ktlint integration [PR#145](https://github.com/novoda/gradle-static-analysis-plugin/pull/145)
- 6.1.0 and 6.2.1 versions are broken for Android projects because of [a bug in Ktlint](https://github.com/JLLeitschuh/ktlint-gradle/issues/153#issuecomment-437176852)
- Make Findbugs Html report generation cacheable [PR#148](https://github.com/novoda/gradle-static-analysis-plugin/pull/148)
- Use Gradle composite builds in sample projects [PR#142](https://github.com/novoda/gradle-static-analysis-plugin/pull/142)
- Improve docs [PR#128](https://github.com/novoda/gradle-static-analysis-plugin/pull/128), [PR#132](https://github.com/novoda/gradle-static-analysis-plugin/pull/132)

[Version 0.6](https://github.com/novoda/gradle-static-analysis-plugin/releases/tag/v0.6)
--------------------------

- Fix release to plugin portal ([PR#82](https://github.com/novoda/gradle-static-analysis-plugin/pull/82),[PR#83](https://github.com/novoda/gradle-static-analysis-plugin/pull/83))
- Fix release to plugin portal ([PR#82](https://github.com/novoda/gradle-static-analysis-plugin/pull/82), [PR#83](https://github.com/novoda/gradle-static-analysis-plugin/pull/83))
- Improve plugin documentation and samples ([PR#85](https://github.com/novoda/gradle-static-analysis-plugin/pull/85),
[PR#97](https://github.com/novoda/gradle-static-analysis-plugin/pull/97),
[PR#99](https://github.com/novoda/gradle-static-analysis-plugin/pull/99),
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ buildscript {
jcenter()
}
dependencies {
classpath 'com.novoda:gradle-static-analysis-plugin:0.6'
classpath 'com.novoda:gradle-static-analysis-plugin:0.7'
}
}
Expand All @@ -52,7 +52,7 @@ or from the [Gradle Plugins Repository](https://plugins.gradle.org/):

```gradle
plugins {
id 'com.novoda.static-analysis' version '0.6'
id 'com.novoda.static-analysis' version '0.7'
}
```
Expand Down
12 changes: 9 additions & 3 deletions docs/tools/ktlint.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
# ktlint
[Ktlint](https://github.com/shyiko/ktlint) is a linter for Kotlin with a built-in formatter. It does not support Java. Adding
this tool only makes sense when you have Kotlin sources in your project. In fact, it will fail to run if you have 0 Kotlin
files.
this tool only makes sense when you have Kotlin sources in your project.

## Table of contents
* [IMPORTANT: setup Ktlint](#important-setup-ktlint)
* [Configure Ktlint](#configure-ktlint)
* [Known Issues](#known-issues)
---

## IMPORTANT: setup Ktlint
Expand All @@ -25,7 +25,7 @@ In most common cases, adding Ktlint to a project boils down to these simple step
1. Add this statement to your root `build.gradle` project (change the version according to your needs):
```gradle
plugins {
id 'org.jlleitschuh.gradle.ktlint' version '5.0.0'
id 'org.jlleitschuh.gradle.ktlint' version '5.1.0'
// ...
}
```
Expand Down Expand Up @@ -56,3 +56,9 @@ For other configuration options and adding custom rules, refer to the

**Note:** Failures and threshold detection is handled by Static Analysis plugin. That is why `ignoreFailures = true` is set by
the plugin. Please do not manually override `ignoreFailures` property.

## Known Issues

6.1.0 and 6.2.1 versions are broken for Android projects because of [a bug in Ktlint](https://github.com/JLLeitschuh/ktlint-gradle/issues/153#issuecomment-437176852)

Because of a behavior change, the `main` sourceSet is not checked. We recommend to use the version 5.1.0 and before.
2 changes: 1 addition & 1 deletion gradle/publish.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ ext {
websiteUrl = 'https://github.com/novoda/gradle-static-analysis-plugin'
}

version = '0.6'
version = '0.7'
String tag = "v$project.version"
groovydoc.docTitle = 'Static Analysis Plugin'

Expand Down
1 change: 0 additions & 1 deletion sample-multi-module/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ apply plugin: 'kotlin-android-extensions'

android {
compileSdkVersion 27
buildToolsVersion '27.0.3'

defaultConfig {
applicationId 'com.novoda.staticanalysis.sample'
Expand Down
9 changes: 5 additions & 4 deletions sample-multi-module/build.gradle
Original file line number Diff line number Diff line change
@@ -1,19 +1,20 @@
buildscript {
ext.kotlin_version = '1.2.60'
ext.kotlin_version = '1.3.0'

repositories {
google()
gradlePluginPortal()
}

dependencies {
classpath 'com.android.tools.build:gradle:3.1.4'
classpath 'com.android.tools.build:gradle:3.2.1'
classpath 'com.novoda:gradle-static-analysis-plugin:local'
classpath 'gradle.plugin.io.gitlab.arturbosch.detekt:detekt-gradle-plugin:1.0.0.RC9'
classpath 'gradle.plugin.org.jlleitschuh.gradle:ktlint-gradle:5.0.0'
classpath 'io.gitlab.arturbosch.detekt:detekt-gradle-plugin:1.0.0-RC10'
classpath 'gradle.plugin.org.jlleitschuh.gradle:ktlint-gradle:5.1.0'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
ext.ReporterType = org.jlleitschuh.gradle.ktlint.reporter.ReporterType

apply from: rootProject.file('team-props/tasks.gradle')

Expand Down
10 changes: 0 additions & 10 deletions sample-multi-module/core/build.gradle
Original file line number Diff line number Diff line change
@@ -1,16 +1,6 @@
apply plugin: 'java-library'
apply plugin: 'kotlin'

buildscript {
ext.kotlin_version = '1.2.30'
repositories {
mavenCentral()
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}

repositories {
mavenCentral()
}
Expand Down
4 changes: 3 additions & 1 deletion sample-multi-module/team-props/static-analysis.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
apply plugin: 'com.novoda.static-analysis'
apply plugin: 'io.gitlab.arturbosch.detekt'
apply plugin: "org.jlleitschuh.gradle.ktlint"
apply plugin: 'org.jlleitschuh.gradle.ktlint'

staticAnalysis {

Expand Down Expand Up @@ -39,6 +39,8 @@ staticAnalysis {
}

ktlint {
reporters = [ReporterType.CHECKSTYLE]

includeVariants { variant -> variant.name.contains('debug') }
}
}
17 changes: 6 additions & 11 deletions sample/app/build.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import org.jlleitschuh.gradle.ktlint.reporter.ReporterType

plugins {
id 'io.gitlab.arturbosch.detekt' version '1.0.0.RC9'
id "org.jlleitschuh.gradle.ktlint" version "5.0.0"
id 'io.gitlab.arturbosch.detekt' version '1.0.0-RC10'
id "org.jlleitschuh.gradle.ktlint"
}

apply plugin: 'com.android.application'
Expand All @@ -18,15 +20,6 @@ android {
versionCode 1
versionName '1.0'
}

buildTypes {
debug {
}
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt')
}
}
}

dependencies {
Expand Down Expand Up @@ -73,6 +66,8 @@ staticAnalysis {

ktlint {
android true
reporters = [ReporterType.CHECKSTYLE]

includeVariants { variant -> variant.name.contains('debug') }
}
}
5 changes: 3 additions & 2 deletions sample/build.gradle
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
buildscript {
ext.kotlin_version = '1.2.60'
ext.kotlin_version = '1.3.0'

repositories {
google()
gradlePluginPortal()
}

dependencies {
classpath 'com.android.tools.build:gradle:3.1.4'
classpath 'com.android.tools.build:gradle:3.2.1'
classpath 'com.novoda:gradle-static-analysis-plugin:local'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath 'gradle.plugin.org.jlleitschuh.gradle:ktlint-gradle:5.1.0'
}
}

Expand Down

0 comments on commit b0a478c

Please sign in to comment.