mirror of https://github.com/embarklabs/embark.git
build: use babel cli's `--extensions` consistently in all packages
If a package uses only `.js` then supply `--extensions ".js"`. If a package uses only `.ts` then supply `--extensions ".ts"`. If a package uses both, then supply `--extensions ".js,.ts"`. The reason for this is that adding/removing TS/JS support ought to occasion revising a package's `package.json` file and adjusting other scripts as well, e.g. for linting. With these changes, it won't work to simply start adding `.ts` files in a package's `src/` directory, which should prompt the developer to review `package.json` and make the appropriate changes, and/or other developers may realize changes need to be made during code review.
This commit is contained in:
parent
142130e533
commit
d5c984c592
|
@ -26,7 +26,7 @@
|
||||||
"dist"
|
"dist"
|
||||||
],
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
"dist"
|
"dist"
|
||||||
],
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".ts\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
"dist"
|
"dist"
|
||||||
],
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
"dist"
|
"dist"
|
||||||
],
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".ts\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps --copy-files",
|
"build": "cross-env BABEL_ENV=node babel src --copy-files --extensions \".ts\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"copy:templates": "cp -rf src/**/*.hbs dist/",
|
"copy:templates": "cp -rf src/**/*.hbs dist/",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
"dist"
|
"dist"
|
||||||
],
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --copy-files --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --copy-files --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
},
|
},
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env BABEL_ENV=node babel src --extensions \".js,.ts\" --out-dir dist --root-mode upward --source-maps",
|
"build": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"lint": "npm-run-all lint:*",
|
"lint": "npm-run-all lint:*",
|
||||||
|
|
|
@ -35,10 +35,10 @@
|
||||||
],
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "npm-run-all build:**",
|
"build": "npm-run-all build:**",
|
||||||
"build:browser": "cross-env BABEL_ENV=browser babel src --out-dir dist/browser --root-mode upward",
|
"build:browser": "cross-env BABEL_ENV=browser babel src --extensions \".js\" --out-dir dist/browser --root-mode upward",
|
||||||
"build:node": "cross-env BABEL_ENV=node babel src --out-dir dist --root-mode upward --source-maps",
|
"build:node": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"build:node:async": "cross-env BABEL_ENV=node:async babel src/node --out-dir dist --root-mode upward --source-maps",
|
"build:node:async": "cross-env BABEL_ENV=node:async babel src/node --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"// build:node:test": "cross-env BABEL_ENV=node:test babel test --out-dir build-test --root-mode upward --source-maps",
|
"// build:node:test": "cross-env BABEL_ENV=node:test babel test --extensions \".js\" --out-dir build-test --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"package": "npm pack",
|
"package": "npm pack",
|
||||||
|
|
|
@ -35,10 +35,10 @@
|
||||||
],
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "npm-run-all build:**",
|
"build": "npm-run-all build:**",
|
||||||
"build:browser": "cross-env BABEL_ENV=browser babel src --out-dir dist/browser --root-mode upward",
|
"build:browser": "cross-env BABEL_ENV=browser babel src --extensions \".js\" --out-dir dist/browser --root-mode upward",
|
||||||
"build:node": "cross-env BABEL_ENV=node babel src --out-dir dist --root-mode upward --source-maps",
|
"build:node": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"build:node:async": "cross-env BABEL_ENV=node:async babel src/node --out-dir dist --root-mode upward --source-maps",
|
"build:node:async": "cross-env BABEL_ENV=node:async babel src/node --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"// build:node:test": "cross-env BABEL_ENV=node:test babel test --out-dir build-test --root-mode upward --source-maps",
|
"// build:node:test": "cross-env BABEL_ENV=node:test babel test --extensions \".js\" --out-dir build-test --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"package": "npm pack",
|
"package": "npm pack",
|
||||||
|
|
|
@ -35,10 +35,10 @@
|
||||||
],
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "npm-run-all build:**",
|
"build": "npm-run-all build:**",
|
||||||
"build:browser": "cross-env BABEL_ENV=browser babel src --out-dir dist/browser --root-mode upward",
|
"build:browser": "cross-env BABEL_ENV=browser babel src --extensions \".js\" --out-dir dist/browser --root-mode upward",
|
||||||
"build:node": "cross-env BABEL_ENV=node babel src --out-dir dist --root-mode upward --source-maps",
|
"build:node": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"build:node:async": "cross-env BABEL_ENV=node:async babel src/node --out-dir dist --root-mode upward --source-maps",
|
"build:node:async": "cross-env BABEL_ENV=node:async babel src/node --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"// build:node:test": "cross-env BABEL_ENV=node:test babel test --out-dir build-test --root-mode upward --source-maps",
|
"// build:node:test": "cross-env BABEL_ENV=node:test babel test --extensions \".js\" --out-dir build-test --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"package": "npm pack",
|
"package": "npm pack",
|
||||||
|
|
|
@ -35,10 +35,10 @@
|
||||||
],
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "npm-run-all build:**",
|
"build": "npm-run-all build:**",
|
||||||
"build:browser": "cross-env BABEL_ENV=browser babel src --out-dir dist/browser --root-mode upward",
|
"build:browser": "cross-env BABEL_ENV=browser babel src --extensions \".js\" --out-dir dist/browser --root-mode upward",
|
||||||
"build:node": "cross-env BABEL_ENV=node babel src --out-dir dist --root-mode upward --source-maps",
|
"build:node": "cross-env BABEL_ENV=node babel src --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"build:node:async": "cross-env BABEL_ENV=node:async babel src/node --out-dir dist --root-mode upward --source-maps",
|
"build:node:async": "cross-env BABEL_ENV=node:async babel src/node --extensions \".js\" --out-dir dist --root-mode upward --source-maps",
|
||||||
"build:node:test": "cross-env BABEL_ENV=node:test babel test --out-dir build-test --root-mode upward --source-maps",
|
"build:node:test": "cross-env BABEL_ENV=node:test babel test --extensions \".js\" --out-dir build-test --root-mode upward --source-maps",
|
||||||
"ci": "npm run qa",
|
"ci": "npm run qa",
|
||||||
"clean": "npm run reset",
|
"clean": "npm run reset",
|
||||||
"package": "npm pack",
|
"package": "npm pack",
|
||||||
|
|
Loading…
Reference in New Issue