Skip to content

Commit 891039d

Browse files
committed
PMD's XML Schemas should be registered in XML Catalog
Fixes #67
1 parent 6a866dd commit 891039d

File tree

5 files changed

+45
-2
lines changed

5 files changed

+45
-2
lines changed

ReleaseNotes.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ Eclipse Update Site:
2020
### Fixed Issues
2121

2222
* [#48](https://github.com/pmd/pmd-eclipse-plugin/issues/48): Upgrade to PMD 6.7.0
23+
* [#67](https://github.com/pmd/pmd-eclipse-plugin/issues/67): PMD's XML Schemas should be registered in XML Catalog
2324

2425
### External Contributions
2526

net.sourceforge.pmd.eclipse.plugin/META-INF/MANIFEST.MF

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@ Require-Bundle: org.apache.commons.logging;bundle-version="1.0.4",
1515
org.eclipse.team.core,
1616
org.eclipse.search,
1717
org.eclipse.help,
18-
org.eclipse.help.ui
18+
org.eclipse.help.ui,
19+
org.eclipse.wst.xml.core
1920
Bundle-ActivationPolicy: lazy
2021
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
2122
Bundle-Vendor: %plugin.provider
@@ -61,6 +62,7 @@ Bundle-ClassPath: target/lib/antlr-runtime.jar,
6162
target/lib/scala-library.jar,
6263
target/lib/scala-reflect.jar,
6364
target/classes/,
65+
target/schema/,
6466
.
6567
Bundle-Localization: plugin
6668
Export-Package: name.herlin.command,

net.sourceforge.pmd.eclipse.plugin/build.properties

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@ bin.includes = .,\
1515
toc.xml,\
1616
welcome.xml,\
1717
doc/,\
18-
target/lib/
18+
target/lib/,\
19+
target/schema/,\
1920
src.includes = icons/,\
2021
META-INF/,\
2122
plugin.xml,\

net.sourceforge.pmd.eclipse.plugin/plugin.xml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -668,5 +668,26 @@
668668
name="PMD UI Commands">
669669
</category>
670670
</extension>
671+
<extension
672+
point="org.eclipse.wst.xml.core.catalogContributions">
673+
<catalogContribution
674+
id="PMD schemas">
675+
<public
676+
id="ruleset_2_0_0"
677+
publicId="http://pmd.sourceforge.net/ruleset/2.0.0"
678+
uri="platform:/plugin/net.sourceforge.pmd.eclipse.plugin/ruleset_2_0_0.xsd">
679+
</public>
680+
<public
681+
id="report_2_0_0"
682+
publicId="http://pmd.sourceforge.net/report/2.0.0"
683+
uri="platform:/plugin/net.sourceforge.pmd.eclipse.plugin/report_2_0_0.xsd">
684+
</public>
685+
<public
686+
id="rule-tests_1_0_0"
687+
publicId="http://pmd.sourceforge.net/rule-tests"
688+
uri="platform:/plugin/net.sourceforge.pmd.eclipse.plugin/rule-tests_1_0_0.xsd">
689+
</public>
690+
</catalogContribution>
691+
</extension>
671692

672693
</plugin>

net.sourceforge.pmd.eclipse.plugin/pom.xml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,24 @@
4747
<phase>process-sources</phase>
4848
<goals><goal>copy-dependencies</goal></goals>
4949
</execution>
50+
<execution>
51+
<id>copy-rule-tests-schema</id>
52+
<phase>process-sources</phase>
53+
<goals>
54+
<goal>unpack</goal>
55+
</goals>
56+
<configuration>
57+
<artifactItems>
58+
<artifactItem>
59+
<groupId>net.sourceforge.pmd</groupId>
60+
<artifactId>pmd-test</artifactId>
61+
<version>${pmd.version}</version>
62+
<includes>rule-tests_1_0_0.xsd</includes>
63+
</artifactItem>
64+
</artifactItems>
65+
<outputDirectory>${project.build.directory}/schema</outputDirectory>
66+
</configuration>
67+
</execution>
5068
</executions>
5169
</plugin>
5270
<plugin>

0 commit comments

Comments
 (0)