Changeset 15588 in josm for trunk/tools/pmd


Ignore:
Timestamp:
2019-12-13T22:12:24+01:00 (5 years ago)
Author:
Don-vip
Message:

tools update: checkstyle 8.27, pmd 6.20, spotbugs 3.1.12

Location:
trunk/tools/pmd
Files:
4 added
9 deleted
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/tools/pmd/designer.bat

    r13202 r15588  
    22set TOPDIR=%~dp0..
    33set OPTS=
    4 set MAIN_CLASS=net.sourceforge.pmd.util.fxdesigner.Designer
     4set MAIN_CLASS=net.sourceforge.pmd.util.fxdesigner.DesignerStarter
    55
    6 java -classpath "%TOPDIR%\pmd\*" %OPTS% %MAIN_CLASS% %*
     6
     7:: sets the jver variable to the java version, eg 901 for 9.0.1+x or 180 for 1.8.0_171-b11
     8:: sets the jvendor variable to either java (oracle) or openjdk
     9for /f tokens^=1^,3^,4^,5^ delims^=.-_+^"^  %%j in ('java -version 2^>^&1 ^| find "version"') do (
     10  set jvendor=%%j
     11  if %%l EQU ea (
     12    set /A "jver=%%k00"
     13  ) else (
     14    set /A jver=%%k%%l%%m
     15  )
     16)
     17
     18Set "jreopts="
     19:: oracle java 9 and 10 has javafx included as a module
     20if /I "%jvendor%" EQU "java" (
     21    if %jver% GEQ 900 (
     22        if %jver% LSS 1100 (
     23            :: enable reflection
     24            Set jreopts=--add-opens javafx.controls/javafx.scene.control.skin=ALL-UNNAMED
     25        )
     26    )
     27)
     28
     29set "_needjfxlib=0"
     30if /I "%jvendor%" EQU "openjdk" set _needjfxlib=1
     31if /I "%jvendor%" EQU "java" (
     32    if %jver% GEQ 1100 set _needjfxlib=1
     33)
     34if %_needjfxlib% EQU 1 (
     35    if %jver% LSS 1000 (
     36        echo For openjfx at least java 10 is required.
     37        pause
     38        exit
     39    )
     40    if [%JAVAFX_HOME%] EQU [] (
     41        echo The environment variable JAVAFX_HOME is missing.
     42        pause
     43        exit
     44    )
     45    set "classpath=%TOPDIR%\pmd\*;%JAVAFX_HOME%\lib\*"
     46) else (
     47    set "classpath=%TOPDIR%\pmd\*"
     48)
     49
     50
     51java %PMD_JAVA_OPTS% %jreopts% -classpath "%classpath%" %OPTS% %MAIN_CLASS% %*
  • trunk/tools/pmd/josm-ruleset.xml

    r14638 r15588  
    1212    <exclude name="ArrayIsStoredDirectly"/>
    1313    <exclude name="AvoidPrintStackTrace"/>
     14    <exclude name="AvoidReassigningLoopVariables"/>
    1415    <exclude name="AvoidReassigningParameters"/>
    1516    <exclude name="AvoidStringBufferField"/>
     
    1718    <exclude name="ConstantsInInterface"/>
    1819    <exclude name="ForLoopCanBeForeach"/>
     20    <exclude name="ForLoopVariableCount"/>
    1921    <exclude name="GuardLogStatement"/>
    2022    <exclude name="JUnit4TestShouldUseAfterAnnotation"/>
     
    162164    <exclude name="BeanMembersShouldSerialize"/>
    163165    <exclude name="CloneThrowsCloneNotSupportedException"/>
     166    <!-- <exclude name="CloseResource"/> -->
    164167    <exclude name="CompareObjectsWithEquals"/>
    165168    <exclude name="ConstructorCallsOverridableMethod"/>
Note: See TracChangeset for help on using the changeset viewer.