vuejs / vuepress

📝 Minimalistic Vue-powered static site generator
https://vuepress.vuejs.org
MIT License
22.43k stars 4.79k forks source link

Add `npm install` and `npm test` to CI #1452

Open bnb opened 5 years ago

bnb commented 5 years ago

Feature request

Add npm install and npm test to the CircleCI build scripts.

What problem does this feature solve?

Currently, the website's front-page implicitly suggests that npm i -g vuepress should work just as well as yarn global add vuepress:

image

It would be awesome to get that same assertion of support in the CI builds so that y'all can ensure there are no possible npm CLI issues before they may be shipped.

The way Yarn and npm resolve dependencies is slightly differently – meaning of the yarn CLI could have a totally fine experience but npm CLI could have an absolutely horrible one. Additionally, Yarn makes no guarantees that dependency resolution will only change with semver major release which only exacerbates this concern as an npm CLI user.

How should this be implemented in your opinion?

Probably as a secondary CI build – i.e. not in the same container as Yarn builds – so you don't have cross-contamination between the two builds.

Are you willing to work on this yourself?

Would be happy to!

ulivz commented 5 years ago

Contribution welcome!

jamesgeorge007 commented 5 years ago

@bnb Are you working on this? @ulivz I would be happy to pick this up if that's not the case :clap:

ulivz commented 5 years ago

@jamesgeorge007 Let go for it!

jamesgeorge007 commented 5 years ago

@ulivz As per what I see adding an npm install and npm test scripts to the CircleCI build config file is what required here :thinking: Kindly suggest me if there is anything worth to be noted :smiley: