jshiell / checkstyle-idea

CheckStyle plug-in for IntelliJ IDEA
https://plugins.jetbrains.com/plugin/1065-checkstyle-idea
Other
889 stars 161 forks source link

Checkstyle requires filling in all values even for those with defaults #635

Closed mjost5v closed 7 months ago

mjost5v commented 7 months ago

Checkstyle doesn't auto fill-in the values with their defaults. Attempting to import a checkstyle file with properties whose values aren't provided but defaults are results in exceptions

jshiell commented 7 months ago

It works for me. Please provide an example file.

Don't forget that value is required by the DTD:

<!ATTLIST property
    name NMTOKEN #REQUIRED
    value CDATA #REQUIRED
    default CDATA #IMPLIED
>

This works in my testing even when checkstyle.suppressions.file is not provided.

<property name="file"
                  value="${checkstyle.suppressions.file}"
                  default="a-suppressions-file.xml"/>
mjost5v commented 7 months ago

That was the issue! Thanks!

On Wed, Mar 27, 2024, 7:38 AM Jamie Shiell @.***> wrote:

It works for me. Please provide an example file.

Don't forget that value is required by the DTD:

<!ATTLIST property name NMTOKEN #REQUIRED value CDATA #REQUIRED default CDATA #IMPLIED

This works in my testing even when checkstyle.suppressions.file is not provided.

<property name="file" value="${checkstyle.suppressions.file}" default="a-suppressions=file.xml"/>

— Reply to this email directly, view it on GitHub https://github.com/jshiell/checkstyle-idea/issues/635#issuecomment-2022555819, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFRCH47U72WDNXHIKUBAR3Y2KOIHAVCNFSM6AAAAABFAA767WVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAMRSGU2TKOBRHE . You are receiving this because you authored the thread.Message ID: @.***>