SonarTsPlugin icon indicating copy to clipboard operation
SonarTsPlugin copied to clipboard

tslint.json should be configured on the server side

Open TristanFAURE opened this issue 8 years ago • 5 comments

Currently (correct me if i'm not wrong) the tslint.json is necessary on client side.

It could be nice to specify it at server side to have all the client using the same

It could be available through a text field containing the json content and before the sonar execution the json file could be created dynamically with the text field content ?

TristanFAURE avatar Jun 02 '17 13:06 TristanFAURE

just put tslint.json into your git repo and all your developers will use the same tslint config

nixel2007 avatar Jun 02 '17 14:06 nixel2007

of course it is a good way to share configuration (and to use it in vs code for instance) but I thought it could make sense

TristanFAURE avatar Jun 02 '17 14:06 TristanFAURE

tslint.json doesn't have to be specified client-side, you could specify it as being on a fileshare or something so long as it's accessible to the scanner machine and user account. However yeah I can see where having a single tslint.json might be beneficial in some environments.

An alternative is to have your CI process run tslint against a centralised tslint.json configuration, and then just reuse the output during the scanner step - this setup works well if you want to fail a build when you get a quality breach but might be heavy-handed.

Pablissimo avatar Jun 07 '17 19:06 Pablissimo

OK thank you for this feedback

TristanFAURE avatar Jun 08 '17 09:06 TristanFAURE

Checkstyle, Findbugs and PMD work this way. You can configure the Rules of these repositories on the server side. You can then download a generated configuration for each of these tools via a permalink. It would be nice to have the same feature here too.

andreasgebauer avatar Jun 30 '17 14:06 andreasgebauer