Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possibility to specify custom reporter via CLI and by .jsinspectrc #59

Open
busybeaver opened this issue Apr 12, 2017 · 3 comments
Open

Comments

@busybeaver
Copy link

busybeaver commented Apr 12, 2017

Hi,

Currently it's only possible to select one of the build in reporters.

It would be great if custom reporter could be specified via CLI or .jsinspectrc config file. It would enable the creation of custom reporters (in separate npm packages)... like it is possible e.g. in JSCPD or ESLint.

In this context, it would probably also make sense to expose the base reporter in the lib/reporters/index.js file to simplify writing custom reporters...

@danielstjules
Copy link
Owner

It would be pretty straightforward to implement. Curious, what sort of custom reporter are you interested in using with the tool?

@busybeaver
Copy link
Author

In my context (we use the tool for projects at work) I can think of two reporters 😄

  • A TeamCity reporter: This can be done quite easy via Build Script Interaction. Obviously it would make sense to publish this one to the public.
  • And then we have some custom internal reporting platform which provides a central place for all kinds of our services/projects health (unit tests, code quality/analysis, E2E tests, open issues, etc.) with dashboards et al. I would like to report the results to this platform. This reporter probably cannot be made public since it would expose some internal information of ours.

Again... would be great if I could be done. I'm happy to assist, e.g. by testing a prerelease version...

@manuc66
Copy link

manuc66 commented Feb 22, 2018

According to https://confluence.jetbrains.com/display/TCD65/Build+Script+Interaction+with+TeamCity#BuildScriptInteractionwithTeamCity-ReportingFxCop

it could be possible to run jsinspect with:

jsinspect -r pmd src/ > coverage.xml
echo "##teamcity[importData type='pmdCpd' path='duplicate.xml']"

and it works! (be warning to specify src/ directory)

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

No branches or pull requests

3 participants