mirror of
https://github.com/meteor/meteor.git
synced 2026-05-02 03:01:46 -04:00
Script for updating to latest versions.
This commit is contained in:
@@ -8,6 +8,13 @@
|
||||
$ npm install --save-dev babel-preset-meteor
|
||||
```
|
||||
|
||||
## Updating dependency versions
|
||||
|
||||
```sh
|
||||
$ cd path/to/babel-preset-meteor
|
||||
$ npm run update-versions
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
||||
### Via `.babelrc` (Recommended)
|
||||
|
||||
@@ -6,6 +6,9 @@
|
||||
"license": "MIT",
|
||||
"repository": "https://github.com/meteor/babel-preset-meteor",
|
||||
"main": "index.js",
|
||||
"scripts": {
|
||||
"update-versions": "bash scripts/update-versions"
|
||||
},
|
||||
"dependencies": {
|
||||
"@babel/plugin-proposal-async-generator-functions": "^7.7.0",
|
||||
"@babel/plugin-proposal-class-properties": "^7.7.0",
|
||||
|
||||
15
scripts/update-versions
Executable file
15
scripts/update-versions
Executable file
@@ -0,0 +1,15 @@
|
||||
#!/usr/bin/env bash -eux
|
||||
|
||||
cd $(dirname $0)/..
|
||||
|
||||
npm i $(node -p 'Object.keys(require("./package.json").dependencies).map(d => d + "@latest").join(" ")')
|
||||
npm i --save-dev --save-exact @babel/core@latest
|
||||
|
||||
git add package.json
|
||||
git commit -m "Update eligible dependencies to latest versions."
|
||||
|
||||
git rm -f package-lock.json
|
||||
rm -rf node_modules
|
||||
npm i
|
||||
git add package-lock.json
|
||||
git commit -m "Update package-lock.json."
|
||||
Reference in New Issue
Block a user