Commit Graph

297 Commits

Author SHA1 Message Date
Haoqun Jiang
ae2a9bc145 fix: fix typo 2018-12-04 20:51:57 +08:00
Patrick
41443944c7 style: small style fixes (#3063)
* style(babel-prompt): Using else if instead of double blocks

* style(Creator): shouldInitGit doesn't need to be async
2018-12-03 20:04:17 +08:00
Haoqun Jiang
1f5f7c35e5 fix: fix cli version check cache 2018-11-30 01:55:06 +08:00
Haoqun Jiang
31ffcfe0ca feat: new release strategy (#3020)
## 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 #2956
2018-11-28 02:12:05 +08:00
Brandon Yeager
42c51c0f62 fix: display project name validation warnings (#2769) 2018-11-26 12:44:06 +08:00
Haoqun Jiang
d1cd4aa6a2 fix: plugin.options can be missing when runGenerator is directly called
fixes #2906
2018-11-12 15:29:40 +08:00
Haoqun Jiang
044f5b3b7e refactor: use a version map to determine the newest dependency versions
Now that lerna independent mode is used to release new versions, we can
no longer ensure the core service/plugin versions are in sync with
@vue/cli itself. So `vue-cli-version-marker` is now used to store the
latest version map of core packages.

In order to automate this process, all the core cli packages are listed
as `devDependencies` of `vue-cli-version-marker`. This will cause a
cyclic dependency warning in lerna bootstrap, and that warning can be
safely ignored because these are just `devDependencies` which won't
affect end users.

Another gotcha is that the version of `vue-cli-version-marker` will be
bumped each time we do a release. This may break the remote version
check logic before rc.12 (due to
1ae223dfc0 (diff-ac5fc3f8b11df9fc948b8e5aa52a074e)
the background version check might never get executed since rc.12)
2018-11-12 14:24:41 +08:00
Haoqun Jiang
b0f6ed8218 feat: support for --registry option in vue add & vue invoke commands (#2698)
closes #1868
2018-10-29 00:07:15 +08:00
Haoqun Jiang
78c7c129dd feat: support yarn for adding inline registry
closes #2809

Yarn supports `--registry` since v1.2.0
2018-10-28 23:28:57 +08:00
katashin
89edf0d341 fix(cli): avoid assertion error when vue.config.js includes assignment expression (#2770) 2018-10-28 11:51:46 +08:00
Yamagishi Kazutoshi
be814b3518 feat(ui): add --host option (#2568) 2018-10-20 19:57:28 +08:00
Haoqun Jiang
7c91a187e4 chore: add link to configuration reference in the generated README.md
fixes #2519
2018-10-09 17:47:37 +08:00
Amy
f99796e627 fix(preset): plugin invoke order don't sort by unicode order (#2656) 2018-10-09 16:59:15 +08:00
Pavan Kumar Sunkara
1a8394434a fix(cli): make sortObject consistent even when keyOrder is given (#2326) 2018-09-25 01:38:33 +08:00
Haoqun Jiang
5e261be0bb fix: show full project name in error message for vue create . 2018-09-19 21:36:17 +08:00
Dobromir Hristov
3f434f69c6 fix(plugin api): fix generator dotfile rename for Windows. (#2427)
close #2424
2018-09-04 17:49:17 +08:00
Haoqun Jiang
ba15fa26b2 fix: use sync fs methods in writeFileTree (#2341)
closes #2275

Iterating over async functions would put too many write calls in I/O
queue in the same time, leading to weird bugs.
2018-09-03 22:34:53 +08:00
The Jared Wilcurt
ff57b8f55f fix: names of Sass and Less (#2384)
* Sass, not SASS

* Update cssPreprocessors.spec.js
2018-08-29 10:25:09 +02:00
dailynodejs
53509e115f [polish] word mistake (#2331)
polish registry word mistake
2018-08-23 17:41:56 +09:00
Haoqun Jiang
ecb8c1801f fix: support generator/index.js in local presets (#2263)
fixes #2172
2018-08-20 11:31:04 -04:00
Evan You
8dfa2907a7 refactor: generate postcss.config.js instead of .postcssrc.js 2018-08-15 18:34:55 -04:00
Evan You
1892bcc251 fix(generator): handle directories starting with dot
close #2222
2018-08-15 18:34:55 -04:00
Evan You
a76bde100b test: do not call process.exit during tests 2018-08-11 16:11:13 -04:00
Evan You
f83f31a02e fix: fix local preset inference on Windows 2018-08-11 16:10:57 -04:00
Evan You
8ccea270d4 chore: ensure EOL on generated files
close #2127
2018-08-10 09:56:23 -04:00
Evan You
3b21fad868 feat: support generator.js and prompts.js in preset 2018-08-08 16:35:57 -04:00
Evan You
1ae223dfc0 refactor: refactor getVersions logic 2018-08-08 11:01:49 -04:00
Guillaume Chau
316d476d6d refactor: launch + more helpful error message 2018-08-06 19:07:05 +02:00
Guillaume Chau
9f9ddb133d feat(create): more descriptions and links 2018-08-06 15:20:24 +02:00
Guillaume Chau
8c96c15682 feat: support ANSI colors in ListItemInfo 2018-08-06 15:04:25 +02:00
李润泽
31710fe4d1 fix: temporarily avoid chalk color in options (#2042) 2018-08-05 23:18:04 -04:00
Evan You
55d266ea30 chore: cli bare flag should take higher priority than preset 2018-08-03 11:47:00 -07:00
Evan You
c6ca93e0dd feat: support --bare flag when creating new projects
close #2030
2018-08-03 11:45:10 -07:00
Evan You
a4ef6bcd7e ci: fix router prompt spec 2018-07-30 18:05:57 -04:00
Evan You
6392a609c1 feat: add create option for router history mode 2018-07-30 18:04:37 -04:00
Evan You
ba43900657 refactor: add invoking flag for generators, fix eslint + ts
close #1972
2018-07-28 15:53:24 -04:00
Guillaume Chau
1c5fdd0184 feat: hasPlugin matches router or vuex 2018-07-28 01:32:49 +02:00
Evan You
b60dd4b6d3 fix: revert windows config path change, close #1961 2018-07-27 09:08:19 -04:00
Evan You
baa1e0455f refactor: extract rc file loading logic 2018-07-26 22:21:16 -04:00
Evan You
e970b1afc3 feat: store rc file in AppData on windows
close #1957
2018-07-26 21:37:30 -04:00
Evan You
ecd0b8d924 chore: handle package.scripts being empty when generating readme 2018-07-24 11:50:38 -04:00
Pavan Kumar Sunkara
17f37187f0 chore: Make the logging consistent and pretty (#1925) 2018-07-24 10:22:13 -04:00
Pavan Kumar Sunkara
e9d01ebde4 fix(create): Commands added by plugin (through preset) won't have description in README' (#1910) 2018-07-24 09:41:19 -04:00
Evan You
967f99abc0 fix(create): fix force git init 2018-07-20 10:33:18 -04:00
Haoqun Jiang
7e6c37c09b fix(create): fix shouldInitGit check (#1901)
Also improve skip git flag description (`--git false` -> `--no-git`)
2018-07-20 06:38:07 -07:00
Evan You
75eb5b1711 fix: plugin generator should be optional
close #1896
2018-07-19 18:14:56 -04:00
Evan You
4b4e4609e5 perf: improve CLI startup performance 2018-07-19 16:41:10 -04:00
Evan You
e33b04c306 feat(plugin-api): prompts.js can now export a function which receives package info 2018-07-18 16:51:13 -04:00
Evan You
ba4d0f285b refactor(generator): ensure proper deep merge of array values in api.extendPackage
Also fixes #970 by injecting eslint config when invoking ts plugin in an existing project
with eslint plugin installed.
2018-07-18 16:44:03 -04:00
Serkan Yerşen
87a6272421 fix(create): prioritize preset name present in ~/.vuerc (#1874)
close #1871
2018-07-17 22:09:39 -04:00