Skip to content

New release strategy #3020

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

Merged
merged 5 commits into from
Nov 27, 2018
Merged

New release strategy #3020

merged 5 commits into from
Nov 27, 2018

Conversation

haoqunjiang
Copy link
Member

Summary

  • Keep package minors in sync (lerna publish --force-publish when releasing a new minor)
  • Patch on demand (lerna publish fixed mode)
  • eslint-config-* packages are published manually

Longer Description

  1. We used to force publish every package till v3.1, this is due to the unbalanced update frequency among different plugins. In practice, some of them, like the pwa plugin, are quite stable and rarely need updating. So force publishing is overkill now.
  2. We have switched to independent mode then, for two major benefits: 1) patching on demand and only on demand 2) eslint config packages needs a more aggressive update strategy in practice, due to the frequent breaking changes in the upstream packages. However, this also causes maintenance burden and confusion to end users. So it's far from ideal.
  3. So now we choose to go back fixed versioning. By default lerna would skip untouched packages when publishing a new version. This might be confusing as we think. So to reduce the cognitive load, we still keep each package's minor field in sync.

Implementation Detail

  1. To selectively publish packages, we have to disable useWorkspaces in lerna so that these packages can be linked by yarn while being unrecognizable to lerna.
  2. Due to an oversight in the old version checking code, version fields in vue-cli-version-marker needs to be exact versions, otherwise cli will throw on startup. So we have to publish vue-cli-version-marker manually after other package updates. This logic can be removed once all users have been upgrade to 3.2.0+ and we can then add it back to packages in lerna.json
  3. We now use ~/.vuerc to cache version check results. This also fixes Vue create fails for not having permission to write to global files #2956

It does nothing more than override the `packages` field in `lerna.json`
with `workspaces` in `package.json`, which casues confusion.

Also, we want to publish eslint-config-* packages & vue-cli-version-marker
separately while still keeping them in the same repo, so this is a must.
@haoqunjiang haoqunjiang merged commit 31ffcfe into vuejs:dev Nov 27, 2018
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.

Vue create fails for not having permission to write to global files
1 participant