[core] Handle quotes correctly in designer.bat and other *.bat files

Fixes #3328
This commit is contained in:
Andreas Dangel 2022-01-13 17:16:07 +01:00
parent 7173f65a87
commit 308173a0fc
No known key found for this signature in database
GPG Key ID: 93450DF2DF9A3FA3
8 changed files with 18 additions and 16 deletions

View File

@ -22,6 +22,8 @@ This is a {{ site.pmd.release_type }} release.
### Fixed Issues
* core
* [#3328](https://github.com/pmd/pmd/issues/3328): \[core] designer.bat errors when JAVAFX_HOME contains spaces
* java-bestpractices
* [#3209](https://github.com/pmd/pmd/issues/3209): \[java] UnusedPrivateMethod false positive with static method and cast expression
* [#3468](https://github.com/pmd/pmd/issues/3468): \[java] UnusedPrivateMethod false positive when outer class calls private static method on inner class

View File

@ -1,6 +1,6 @@
@echo off
set TOPDIR=%~dp0..
set TOPDIR="%~dp0.."
set OPTS=
set MAIN_CLASS=net.sourceforge.pmd.util.treeexport.TreeExportCli
java %PMD_JAVA_OPTS% -classpath "%TOPDIR%\lib\*" %OPTS% %MAIN_CLASS% %*
java %PMD_JAVA_OPTS% -classpath %TOPDIR%\lib\* %OPTS% %MAIN_CLASS% %*

View File

@ -1,6 +1,6 @@
@echo off
set TOPDIR=%~dp0..
set TOPDIR="%~dp0.."
set OPTS=
set MAIN_CLASS=net.sourceforge.pmd.util.viewer.Viewer
java %PMD_JAVA_OPTS% -classpath "%TOPDIR%\lib\*" %OPTS% %MAIN_CLASS% %*
java %PMD_JAVA_OPTS% -classpath %TOPDIR%\lib\* %OPTS% %MAIN_CLASS% %*

View File

@ -1,6 +1,6 @@
@echo off
set TOPDIR=%~dp0..
set TOPDIR="%~dp0.."
set OPTS=
set MAIN_CLASS=net.sourceforge.pmd.cpd.CPD
java %PMD_JAVA_OPTS% -classpath "%TOPDIR%\lib\*" %OPTS% %MAIN_CLASS% %*
java %PMD_JAVA_OPTS% -classpath %TOPDIR%\lib\* %OPTS% %MAIN_CLASS% %*

View File

@ -1,6 +1,6 @@
@echo off
set TOPDIR=%~dp0..
set TOPDIR="%~dp0.."
set OPTS=
set MAIN_CLASS=net.sourceforge.pmd.cpd.GUI
java %PMD_JAVA_OPTS% -classpath "%TOPDIR%\lib\*" %OPTS% %MAIN_CLASS% %*
java %PMD_JAVA_OPTS% -classpath %TOPDIR%\lib\* %OPTS% %MAIN_CLASS% %*

View File

@ -1,5 +1,5 @@
@echo off
set TOPDIR=%~dp0..
set TOPDIR="%~dp0.."
set OPTS=
set MAIN_CLASS=net.sourceforge.pmd.util.fxdesigner.DesignerStarter
@ -42,10 +42,10 @@ if %_needjfxlib% EQU 1 (
pause
exit
)
set "classpath=%TOPDIR%\lib\*;%JAVAFX_HOME%\lib\*"
set classpath=%TOPDIR%\lib\*;%JAVAFX_HOME%\lib\*
) else (
set "classpath=%TOPDIR%\lib\*"
set classpath=%TOPDIR%\lib\*
)
java %PMD_JAVA_OPTS% %jreopts% -classpath "%classpath%" %OPTS% %MAIN_CLASS% %*
java %PMD_JAVA_OPTS% %jreopts% -classpath %classpath% %OPTS% %MAIN_CLASS% %*

View File

@ -1,6 +1,6 @@
@echo off
set TOPDIR=%~dp0..
set TOPDIR="%~dp0.."
set OPTS=
set MAIN_CLASS=net.sourceforge.pmd.util.designer.Designer
java %PMD_JAVA_OPTS% -classpath "%TOPDIR%\lib\*" %OPTS% %MAIN_CLASS% %*
java %PMD_JAVA_OPTS% -classpath %TOPDIR%\lib\* %OPTS% %MAIN_CLASS% %*

View File

@ -1,6 +1,6 @@
@echo off
set TOPDIR=%~dp0..
set TOPDIR="%~dp0.."
set OPTS=
set MAIN_CLASS=net.sourceforge.pmd.PMD
java %PMD_JAVA_OPTS% -classpath "%TOPDIR%\lib\*" %OPTS% %MAIN_CLASS% %*
java %PMD_JAVA_OPTS% -classpath %TOPDIR%\lib\* %OPTS% %MAIN_CLASS% %*