在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称(OpenSource Name):nebula-plugins/gradle-lint-plugin开源软件地址(OpenSource Url):https://github.com/nebula-plugins/gradle-lint-plugin开源编程语言(OpenSource Language):Groovy 97.5%开源软件介绍(OpenSource Introduction):Gradle Lint PluginPurposeThe Gradle Lint plugin is a pluggable and configurable linter tool for identifying and reporting on patterns of misuse or deprecations in Gradle scripts and related files. It is inspired by the excellent ESLint tool for Javascript and by the formatting in NPM's eslint-friendly-formatter package. It assists a centralized build tools team in gently introducing and maintaining a standard build script style across their organization. Getting StartedRead the full documentation. To apply this plugin, please get the latest version from the Gradle plugin portal and add the following to buildscript { repositories { mavenCentral() } }
plugins {
id 'nebula.lint' version '<latest version from the Gradle plugin portal>'
} Important: For now, in a multi-module build you must apply lint to the root project, at a minimum. Alternatively: buildscript {
repositories { mavenCentral() }
dependencies {
classpath 'com.netflix.nebula:gradle-lint-plugin:latest.release'
}
}
apply plugin: 'nebula.lint' Define which rules you would like to lint against: gradleLint.rules = ['all-dependency'] // add as many rules here as you'd like For an enterprise build, we recommend defining the lint rules in a For multimodule projects, we recommend applying the plugin in an allprojects block: allprojects {
apply plugin: 'nebula.lint'
gradleLint.rules = ['all-dependency'] // add as many rules here as you'd like
} api/implementation supportv15.0.0 introduced api/implementation configuration support. This allows to show warnings around api/implementation configurations Since we need to do some major work to keep track of declared configurations and then replace code with the proper configuration, we decided to just show warnings for now. This work includes finding dependency information for non resolvable configurations so we look into the parents If gradle/gradle#11106 lands some day, we could definitely enhance this experience. While it is great to have automatic fix, not having it is worse. So for now warning about this with the same detail as before is much better than a broken experience with new gradle configurations WarningGradle Lint Plugin currently doesn't support:
LicenseCopyright 2015-2018-2019 Netflix, Inc. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论