Update documentation
https://github.com/pmd/pmd/actions/runs/4017023623
614a574292...30a01c4f33
This commit is contained in:
4
feed.xml
4
feed.xml
@ -5,8 +5,8 @@
|
||||
<description>Intended as a documentation theme based on Jekyll for technical writers documenting software and other technical products, this theme has all the elements you would need to handle multiple products with both multi-level sidebar navigation, tags, and other documentation features.</description>
|
||||
<link>https://pmd.github.io/pmd/</link>
|
||||
<atom:link href="https://pmd.github.io/pmd/feed.xml" rel="self" type="application/rss+xml"/>
|
||||
<pubDate>Thu, 26 Jan 2023 15:05:09 +0000</pubDate>
|
||||
<lastBuildDate>Thu, 26 Jan 2023 15:05:09 +0000</lastBuildDate>
|
||||
<pubDate>Thu, 26 Jan 2023 16:41:50 +0000</pubDate>
|
||||
<lastBuildDate>Thu, 26 Jan 2023 16:41:50 +0000</lastBuildDate>
|
||||
<generator>Jekyll v3.9.2</generator>
|
||||
|
||||
</channel>
|
||||
|
@ -1622,6 +1622,7 @@ with charting functions. It uses an XSLT stylesheet to convert PMD’s XML forma
|
||||
</li>
|
||||
<li>core
|
||||
<ul>
|
||||
<li><a href="https://github.com/pmd/pmd/issues/4026">#4026</a>: [cli] Filenames printed as absolute paths in the report despite parameter <code class="language-plaintext highlighter-rouge">--short-names</code></li>
|
||||
<li><a href="https://github.com/pmd/pmd/issues/4279">#4279</a>: [core] Can not set ruleset property value to empty</li>
|
||||
<li><a href="https://github.com/pmd/pmd/pull/4329">#4329</a>: [core] Refactor usage of snakeyaml</li>
|
||||
<li><a href="https://github.com/pmd/pmd/issues/4340">#4340</a>: [core] Allow to filter found matches in CPDReport</li>
|
||||
@ -1636,6 +1637,15 @@ with charting functions. It uses an XSLT stylesheet to convert PMD’s XML forma
|
||||
|
||||
<h3 id="api-changes">API Changes</h3>
|
||||
|
||||
<h4 id="pmd-cli">PMD CLI</h4>
|
||||
|
||||
<ul>
|
||||
<li>PMD now supports a new <code class="language-plaintext highlighter-rouge">--relativize-paths-with</code> flag (or short <code class="language-plaintext highlighter-rouge">-z</code>), which replaces <code class="language-plaintext highlighter-rouge">--short-names</code>.
|
||||
It serves the same purpose: Shortening the pathnames in the reports. However, with the new flag it’s possible
|
||||
to explicitly define one or more pathnames that should be used as the base when creating relative paths.
|
||||
The old flag <code class="language-plaintext highlighter-rouge">--short-names</code> is deprecated.</li>
|
||||
</ul>
|
||||
|
||||
<h4 id="deprecated-apis">Deprecated APIs</h4>
|
||||
|
||||
<h5 id="for-removal">For removal</h5>
|
||||
@ -1654,7 +1664,17 @@ for <code class="language-plaintext highlighter-rouge">CPDConfiguration</code> w
|
||||
replacement. CLI tests should be done in pmd-core only (and in PMD7 in pmd-cli). Individual language modules
|
||||
shouldn’t need to test the CLI integration logic again. Instead, the individual language modules should test their
|
||||
functionality as unit tests.</li>
|
||||
<li><a href="https://docs.pmd-code.org/apidocs/pmd-core/6.54.0-SNAPSHOT/net/sourceforge/pmd/cpd/CPDConfiguration.LanguageConverter.html#"><code>CPDConfiguration.LanguageConverter</code></a></li>
|
||||
<li>
|
||||
<p><a href="https://docs.pmd-code.org/apidocs/pmd-core/6.54.0-SNAPSHOT/net/sourceforge/pmd/cpd/CPDConfiguration.LanguageConverter.html#"><code>CPDConfiguration.LanguageConverter</code></a></p>
|
||||
</li>
|
||||
<li>
|
||||
<p><a href="https://docs.pmd-code.org/apidocs/pmd-core/6.54.0-SNAPSHOT/net/sourceforge/pmd/lang/document/FileCollector.html#addZipFile(java.nio.file.Path)"><code>FileCollector#addZipFile</code></a> has been deprecated. It is replaced
|
||||
by <a href="https://docs.pmd-code.org/apidocs/pmd-core/6.54.0-SNAPSHOT/net/sourceforge/pmd/lang/document/FileCollector.html#addZipFileWithContent(java.nio.file.Path)"><code>FileCollector#addZipFileWithContent</code></a> which directly adds the
|
||||
content of the zip file for analysis.</p>
|
||||
</li>
|
||||
<li><a href="https://docs.pmd-code.org/apidocs/pmd-core/6.54.0-SNAPSHOT/net/sourceforge/pmd/PMDConfiguration.html#setReportShortNames(boolean)"><code>PMDConfiguration#setReportShortNames</code></a> and
|
||||
<a href="https://docs.pmd-code.org/apidocs/pmd-core/6.54.0-SNAPSHOT/net/sourceforge/pmd/PMDConfiguration.html#isReportShortNames()"><code>PMDConfiguration#isReportShortNames</code></a> have been deprecated for removal.
|
||||
Use <a href="https://docs.pmd-code.org/apidocs/pmd-core/6.54.0-SNAPSHOT/net/sourceforge/pmd/PMDConfiguration.html#addRelativizeRoot(java.nio.file.Path)"><code>PMDConfiguration#addRelativizeRoot</code></a> instead.</li>
|
||||
</ul>
|
||||
|
||||
<h5 id="internal-apis">Internal APIs</h5>
|
||||
|
@ -1970,7 +1970,8 @@
|
||||
|
||||
<tr>
|
||||
<td><a style="pointer-events: none; cursor: default;" name="language"><code>-language <lang></code><br /><code>-l <lang></code></a></td>
|
||||
<td>Specify the language PMD should use. Used together with <code>-version</code>. See also <a href="#supported-languages">Supported Languages</a>.</td>
|
||||
<td>Specify the language PMD should use. Used together with <code>-version</code>. See also <a href="#supported-languages">Supported Languages</a>.
|
||||
<p><span class="label label-default">Deprecated</span> since PMD 6.52.0. Use <code>--use-version</code> instead.</p></td>
|
||||
<td><code></code></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
@ -2076,6 +2077,32 @@
|
||||
|
||||
|
||||
|
||||
<!-- fragment id in the page -->
|
||||
|
||||
|
||||
<tr>
|
||||
<td><a style="pointer-events: none; cursor: default;" name="-relativize-paths-with"><code>--relativize-paths-with <path></code><br /><code>-z <path></code></a></td>
|
||||
<td>Path relative to which directories are rendered in the report. This option allows
|
||||
shortening directories in the report; without it, paths are rendered as mentioned in the source directory (option "--dir").
|
||||
The option can be repeated, in which case the shortest relative path will be used.
|
||||
If the root path is mentioned (e.g. "/" or "C:\\"), then the paths will be rendered as absolute.
|
||||
This option replaces <code>--short-names</code> since PMD 6.54.0.</td>
|
||||
<td><code></code></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
|
||||
<!-- Row of the CLI reference table, describing an option -->
|
||||
<!-- Rows can be linked to the name of the option (without leading dash) -->
|
||||
<!-- Argument summary: -->
|
||||
<!-- options: comma separated list of aliases for the option.-->
|
||||
<!-- option_arg: optional name for the argument of the option, eg 'arg', will be formatted eg to '<arg>'-->
|
||||
<!-- description: description, you can use "some" inline markdown -->
|
||||
<!-- required: whether the option is required, if specified, whatever the value, it's considered required -->
|
||||
<!-- languages: languages to which the option applies -->
|
||||
<!-- default: default value -->
|
||||
|
||||
|
||||
|
||||
<!-- fragment id in the page -->
|
||||
|
||||
|
||||
@ -2103,7 +2130,8 @@
|
||||
|
||||
<tr>
|
||||
<td><a style="pointer-events: none; cursor: default;" name="-short-names"><code>--short-names</code></a></td>
|
||||
<td>Prints shortened filenames in the report.</td>
|
||||
<td>Prints shortened filenames in the report.
|
||||
<p><span class="label label-default">Deprecated</span> since PMD 6.54.0. Use <code>--relativize-paths-with</code> instead.</p></td>
|
||||
<td><code></code></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
@ -2258,7 +2286,8 @@
|
||||
|
||||
<tr>
|
||||
<td><a style="pointer-events: none; cursor: default;" name="version"><code>-version <version></code><br /><code>-v <version></code></a></td>
|
||||
<td>Specify the version of a language PMD should use. Used together with <code>-language</code>. See also <a href="#supported-languages">Supported Languages</a>.</td>
|
||||
<td>Specify the version of a language PMD should use. Used together with <code>-language</code>. See also <a href="#supported-languages">Supported Languages</a>.
|
||||
<p><span class="label label-default">Deprecated</span> since PMD 6.52.0. Use <code>--use-version</code> instead.</p></td>
|
||||
<td><code></code></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
|
@ -1671,7 +1671,11 @@ then you can make use of the PMD Task like this:</p>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>shortFilenames</td>
|
||||
<td>Places truncated filenames in the report. This can reduce your report file size by 15%-20%.</td>
|
||||
<td>
|
||||
<span class="label label-default">Deprecated</span> Use <code>relativizePathsWith</code>
|
||||
as nested element instead.
|
||||
Places truncated filenames in the report. This can reduce your report file size by 15%-20%.
|
||||
</td>
|
||||
<td>No</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@ -1777,7 +1781,7 @@ automatically and the latest language version is used.</p>
|
||||
|
||||
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code><target name="pmd">
|
||||
<taskdef name="pmd" classname="net.sourceforge.pmd.ant.PMDTask"/>
|
||||
<pmd shortFilenames="true">
|
||||
<pmd>
|
||||
<ruleset>rulesets/java/quickstart.xml</ruleset>
|
||||
<ruleset>config/my-ruleset.xml</ruleset>
|
||||
<fileset dir="/usr/local/j2sdk1.4.1_01/src/">
|
||||
@ -1790,6 +1794,12 @@ automatically and the latest language version is used.</p>
|
||||
<p><code class="language-plaintext highlighter-rouge">fileset</code> nested element - specify the actual java source files, that PMD should analyze. You can use multiple
|
||||
fileset elements. See <a href="https://ant.apache.org/manual/Types/fileset.html">FileSet</a> for the syntax and usage.</p>
|
||||
|
||||
<p><code class="language-plaintext highlighter-rouge">relativizePathsWith</code> nested element - configures the paths relative to which directories are rendered in the report.
|
||||
This option allows shortening directories in the report; without it, paths are rendered as absolute paths.
|
||||
The option can be repeated, in which case the shortest relative path will be used.
|
||||
It is a <a href="https://ant.apache.org/manual/using.html#path">path-like structure</a>.
|
||||
This option replaces <code class="language-plaintext highlighter-rouge">shortFilenames</code> since PMD 6.54.0.</p>
|
||||
|
||||
<h3 id="language-version-selection">Language version selection</h3>
|
||||
|
||||
<p>PMD selects the language automatically using the file extension. If multiple versions of a language are
|
||||
@ -2009,7 +2019,7 @@ Total time: 2 seconds
|
||||
|
||||
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code><target name="pmd">
|
||||
<taskdef name="pmd" classname="net.sourceforge.pmd.ant.PMDTask"/>
|
||||
<pmd rulesetfiles="rulesets/java/quickstart.xml" shortFilenames="true">
|
||||
<pmd rulesetfiles="rulesets/java/quickstart.xml">
|
||||
<formatter type="html" toFile="pmd_report.html">
|
||||
<param name="linkPrefix" value="https://maven.apache.org/plugins/maven-pmd-plugin/xref/"/>
|
||||
<param name="linePrefix" value="L"/>
|
||||
@ -2017,6 +2027,9 @@ Total time: 2 seconds
|
||||
<fileset dir="/usr/local/j2sdk1.4.1_01/src/">
|
||||
<include name="java/lang/*.java"/>
|
||||
</fileset>
|
||||
<relativizePathsWith>
|
||||
<pathelement location="/usr/local/j2sdk1.4.1_01/src/"/>
|
||||
</relativizePathsWith>
|
||||
</pmd>
|
||||
</target>
|
||||
</code></pre></div></div>
|
||||
|
Reference in New Issue
Block a user