eclipse-pmd:Eclipse IDE的PMD插件

  • Q0_710158
    了解作者
  • 1MB
    文件大小
  • zip
    文件格式
  • 0
    收藏次数
  • VIP专享
    资源类型
  • 0
    下载次数
  • 2022-05-26 03:51
    上传日期
蚀pmd eclipse-pmd插件将著名的源代码分析器PMD集成到Eclipse IDE中。 每次保存工作时,eclipse-pmd都会扫描源代码并查找潜在的问题,例如可能的错误以及次优,重复,无效或过于复杂的代码。 eclipse-pmd在可能的情况下提供了快速修复程序,可以自动修复问题。 这些快速修复程序可用于修复整个代码库中的单个问题或所有出现的问题。 如何开始 您需要Eclipse 2019-12或更高版本以及Java 11或更高版本才能运行eclipse-pmd。 请按照网站上有关说明进行操作。 如何构建和安装eclipse-pmd 构建eclipse-pmd非常容易。 但
eclipse-pmd-main.zip
内容介绍
# eclipse-pmd The eclipse-pmd plug-in integrates the well-known source code analyzer PMD into the Eclipse IDE. Everytime you save your work, eclipse-pmd scans your source code and looks for potential problems like possible bugs and suboptimal, duplicate, dead or overly complicated code. Where possible, eclipse-pmd offers quick fixes that automatically fix the problems. These quick fixes can be used to fix a single problem or all occurrences in your entire code base. ## How to get started You need Eclipse 2019-12 or later and Java 11 or later to run eclipse-pmd. Please follow the instructions on [how to get started with eclipse-pmd](https://eclipse-pmd.github.io/getting-started.html) on the website. ## How to build and install eclipse-pmd Building eclipse-pmd is fairly easy. Please note, however, that building eclipse-pmd is not required if you are only interested in using it, since there is a pre-built version available in the Eclipse Marketplace. ### Requirements You need the following tools: * JDK 11 * Maven 3 * Git ### Build instructions The first thing you need to do is to check out the source code. ``` git clone https://github.com/eclipse-pmd/eclipse-pmd.git cd eclipse-pmd ``` Once you have the source code you can build it with Maven. ``` cd ch.acanda.eclipse.pmd mvn clean verify ``` This will compile, test and build a local repository for eclipse-pmd. If the build was successful you will find the repository in `ch.acanda.eclipse.pmd.repository/target/repository`. ### Installation Once you have built the repository you can install eclipse-pmd by adding a new repository to Eclipse: * from within Eclipse select `Help` > `Install New Software...` * click the button `Add...` of the `Install` dialog * click the button `Local...` of the `Add Repository` dialog * select the folder `ch.acanda.eclipse.pmd.repository/target/repository` * click the button `OK` of the `Add Repository` dialog * select `Eclipse PMD Plug-in` and proceed with the installation From now on you can simply update Eclipse with `Help` > `Check for Updates` after you rebuilt eclipse-pmd. ### Testing against different Eclipse releases Building eclipse-pmd with `mvn clean verify` compiles and tests it against the oldest supported release of Eclipse which is Eclipse 2019-12. To ensure eclipse-pmd also works with newer releases the Eclipse release can be set with the parameter `eclipse-release`. Compile and test against Eclipse 2019-12: `mvn clean verify -Declipse-release=2019-12` Compile and test against Eclipse 2020-03: `mvn clean verify -Declipse-release=2020-03` Compile and test against Eclipse 2020-06: `mvn clean verify -Declipse-release=2020-06` Compile and test against Eclipse 2020-09: `mvn clean verify -Declipse-release=2020-09` Regardless of the chosen release, the built plug-in will always be the same as the one built without the parameter. So there isn't any advantage in building the plug-in yourself if you are using a newer Eclipse release.
评论
    相关推荐