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

feat: migrating utility modules to monorepo #4

Merged
merged 4 commits into from
Mar 20, 2017
Merged

feat: migrating utility modules to monorepo #4

merged 4 commits into from
Mar 20, 2017

Conversation

bcoe
Copy link
Member

@bcoe bcoe commented Mar 14, 2017

this moves us closer to wrapping up the work on migrating our utility modules into a monorepo:

  • adding a top-level test-runner.
  • taking a rough stab at a README better explaining the motivation around this monorepo (I would love some help editing this).

I'm convinced that moving to a monorepo will help better centralize bug tracking, and will keep conversations centered around the more interesting modules in the istanbul ecosystem.

Not a blocker ... but ...

I would love some help debugging why the istanbul-api tests have trouble running when instrumented with nyc.

Copy link
Member

@JaKXz JaKXz left a comment

Choose a reason for hiding this comment

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

This is looking good! Loving the reduction of duplication. And the README is great, nothing to change there other than adding a ## Quick Start for contributing / getting tests running etc.

package.json Outdated
@@ -1,5 +1,32 @@
{
"name": "istanbuljs",
"version": "1.0.0",
Copy link
Member

Choose a reason for hiding this comment

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

We're calling this the supporting libraries for the IstanbulJS 2.0 CLI, so shouldn't this start at 2.0.0?

Copy link
Member Author

Choose a reason for hiding this comment

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

@JaKXz slightly confusing I know, but we've been using 2.x to refer to the process of splitting Istanbul into a series of packages rather than one monolith -- I don't disagree with you, but I think it might not be worth a major bump since several libraries rely on these modules already and it would be confusing to them.

Copy link
Member

Choose a reason for hiding this comment

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

But this is just an internal number right? Are external deps requiring istanbuljs right now? Unless I'm misunderstanding a lerna concept right now...

Copy link
Member Author

Choose a reason for hiding this comment

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

oh, shoot! you are 100% right :p I was thinking you meant the packages within the repo -- because I'm bad at reading.

Copy link
Member

@JaKXz JaKXz Mar 15, 2017

Choose a reason for hiding this comment

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

haha no worries. One more question though, will this increment in minor versions [only] for any changes to sub-packages, except breaking changes? That would make sense to me... though I'm not entirely sure.

Or do we want to go with the babel versioning system and start at [an arbitrary version i.e.] v10 [i.e. like nyc] and increment everything together?

"scripts": {
"test": "cross-env LERNA_TEST_RUN=1 nyc lerna exec npm test",
"postinstall": "lerna bootstrap",
"release": "lerna publish --conventional-commits"
Copy link
Member

Choose a reason for hiding this comment

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

🔥

"test": "istanbul cover -x 'docs/**' --include-all-sources --print=both _mocha -- test/",
"posttest": "istanbul check-coverage --statements 95 --branches 80",
"release": "standard-version"
"test": "_mocha -- test/"
Copy link
Member

Choose a reason for hiding this comment

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

nit: extra space here

@@ -7,8 +7,7 @@
"scripts": {
"fast": "mocha test/",
"pretest": "jshint index.js lib/ test/",
"test": "istanbul cover -x 'docs/**' --include-all-sources --print=both _mocha -- test/",
"xposttest": "istanbul check-coverage --statements 95 --branches 80"
"test": "_mocha -- test/"
Copy link
Member

Choose a reason for hiding this comment

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

another nit

"test": "istanbul cover --include-all-sources --print=both _mocha -- test/",
"xposttest": "istanbul check-coverage --statements 95 --branches 80",
"release": "standard-version"
"test": "_mocha -- test/"
Copy link
Member

Choose a reason for hiding this comment

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

another nit.

Question, though, why do these use the _mocha executable while istanbul-reports doesn't?

Copy link
Member Author

Choose a reason for hiding this comment

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

this is an Istanbul thing, we could switch to mocha; it might be worthwhile to do so.

_mocha doesn't spawn a subprocess mocha does.

Copy link
Member

Choose a reason for hiding this comment

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

I would vote for switching, since that will be more consistent with 'correct' usage patterns... and would serve as a pseudo acceptance test...

.travis.yml Outdated
node_js:
- '4'
- '6'
- '7'
Copy link
Member

Choose a reason for hiding this comment

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

I recommend using the 'stable' keyword instead of specifying non-LTS versions so it's one less thing to maintain as time goes on.

@graingert
Copy link
Collaborator

graingert commented Mar 14, 2017

@bcoe is it worth recreating the big unification commit? 8c4a22f

Or should we recreate it, and rebase all the changes, the exact atomic moment we switch from multi-repo to mono-repo?

@bcoe
Copy link
Member Author

bcoe commented Mar 14, 2017

@graingert nope :) I see this as the first pull request on top of the unification pull-request 👍

Also, cool thing worth noting as we pull in a few more libraries., there's a lerna import now -- which I was playing with for conventional-commits.

@bcoe bcoe merged commit 18417be into master Mar 20, 2017
@bcoe bcoe deleted the tests-etc branch March 20, 2017 01:46
bcoe added a commit that referenced this pull request Mar 20, 2017
Yukaii pushed a commit to hackmdio/istanbuljs that referenced this pull request Mar 12, 2019
vivek-freshworks pushed a commit to freshworks/istanbuljs that referenced this pull request Oct 17, 2023
arnabsen pushed a commit to arnabsen/istanbuljs that referenced this pull request Feb 20, 2024
arnabsen pushed a commit to arnabsen/istanbuljs that referenced this pull request Feb 20, 2024
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.

None yet

3 participants