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

Add insight dependency to anonymously report usage metrics #34

Open
1 of 7 tasks
bmpvieira opened this issue Jul 6, 2016 · 3 comments
Open
1 of 7 tasks

Add insight dependency to anonymously report usage metrics #34

bmpvieira opened this issue Jul 6, 2016 · 3 comments

Comments

@bmpvieira
Copy link
Member

bmpvieira commented Jul 6, 2016

We should probably add yeoman/insight ASAP to all modules with .askPermission() enabled by default. This data could be very useful when applying for future grants.

  • bionode-ncbi
  • bionode-watermill
  • bionode-fasta
  • bionode-seq
  • bionode-sra
  • bionode-quickgo
  • etc
@thejmazz
Copy link
Member

thejmazz commented Jul 6, 2016

Good idea, looking at the readme, I think you create URLs to display info about specific commands?

So like

insight.track('ncbi', 'download')

and

insight.track('ncbi', 'search')

for the NCBI module would count how many times specific commands were called?

And at a more basic level, keep track of which modules are being installed.

Could also be cool to get CLI vs. require metrics.

Is this something that is triggered after npm install? I think you can identify a script to run in package.json after install finishes, so it could probably be put there.

@tiagofilipe12
Copy link
Member

It would help if you have the bionode-ncbi example implementation somehow documented here.

@bmpvieira
Copy link
Member Author

Do:

git clone git@github.com:bionode/bionode-MODULE_NAME.git
cd bionode-MODULE_NAME
npm install --save-dev insight

Then add to the lib folder the anonymous-tracking.js file.

Require that file in the main module JS file.
Add tracking to relevant functions, i.e., functions that are part of the API and that we want to track usage. The format should be:

insight.track('MODULE_NAME_SUFFIX', 'FUNCTION_NAME')
# Example
insight.track('ncbi', 'search')

Also add tracking to CLI.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants