Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

filipesperandio
Copy link
Contributor

@filipesperandio filipesperandio commented Sep 25, 2017

pmd:
  enabled: true
  config:
    rules:
      - "java-basic"
      - "java-design"

"enabled": true,
"channel": "beta",
"config": {
"rules": "java-basic,java-design"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason why this isn't an array (instead of a string with a comma-separated list)?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because I am stupid I guess... =/

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ha, no way! 😛

Just a suggestion to simplify parsing. 😄

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually we just forward the entire thing, I think that was the reason I didn't bother to split, but I makes more sense from a yml perspective to have it as an array.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@toddmazierski Adjusted.

@Test
public void acceptRulesSimpleNames() {
def config = new Config([configFile: "/usr/src/app/fixtures/rules/config.json", codeFolder: "/usr/src/app/fixtures/rules"])
assertEquals "java-basic,java-design", config.ruleSet()

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this assertion be adjusted?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's the argument for the command line, should still be a single string.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, my mistake.

Should config.mix.json still contain a comma-separated string, though?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does not impact, but it should be adjusted. 👍

Copy link

@toddmazierski toddmazierski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚢

@filipesperandio filipesperandio merged commit a427807 into master Sep 25, 2017
@filipesperandio filipesperandio deleted the fe/rules2 branch September 25, 2017 21:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants