title: How can I get Gradle to use PMD 6.x categories?
body: <p>I am using Gradle 4.5.1 and the standard Gradle plugin. I have specifically requested that my build use PMD 6.1.0, like so:</p>
  
  <pre><code>apply plugin: "pmd"
  
  pmd {
      toolVersion = "6.1.0"
  }
  
  pmdMain {
      rulSets = ["java-basic"]
  }
  </code></pre>
  
  <p>Everything passes, but I get a number of deprecation warnings in the console along the lines of this:</p>
  
  <blockquote>
    <p>Use Rule name <code>category/java/errorprone.xml/AvoidBranchingStatementAsLastInLoop</code> instead of the deprecated Rule name <code>rulesets/java/basic.xml/AvoidBranchingStatementAsLastInLoop</code>. PMD 7.0.0 will remove support for this deprecated Rule name usage.</p>
  </blockquote>
  
  <p>My initial thought was to change the <code>pmdMain</code> block like so:</p>
  
  <pre><code>pmdMain {
      rulSets = ["java-errorprone"]
  }
  </code></pre>
  
  <p>However, I get this error:</p>
  
  <blockquote>
    <p>Can't find resource 'null' for rule 'java-errorprone'.  Make sure the resource is a valid file or URL and is on the CLASSPATH. Here's the current classpath: <code>~\.gradle\wrapper\dists\gradle-4.5.1-bin\a5vbgfvpwtoqz8v2cdivxz28k\gradle-4.5.1\lib\gradle-launcher-4.5.1.jar</code></p>
  </blockquote>
  
  <p>Is there something I'm doing wrong? Is Gradle's PMD plugin incompatible with PMD 6.x?</p>