mirror of
https://github.com/hanzoai/babel.git
synced 2026-09-24 16:56:45 +00:00
* improve * doc * fix * improve * improve * update and fix * pack dependencies * Update Makefile.mjs Co-authored-by: Nicolò Ribaudo <[email protected]> * review * fix node6 * fix * terser Co-authored-by: Nicolò Ribaudo <[email protected]>
26 lines
622 B
JavaScript
26 lines
622 B
JavaScript
import { readFileSync, writeFileSync } from "fs";
|
|
import shell from "shelljs";
|
|
import path from "path";
|
|
|
|
console.log("Cloning LICENSE to babel packages");
|
|
|
|
const LICENSE = readFileSync("LICENSE", "utf8");
|
|
|
|
console.log(LICENSE);
|
|
|
|
shell.ls("-d", "./packages/*/").forEach(dir => {
|
|
if (
|
|
!dir.match(
|
|
/.*packages\/(babel-parser|babel-plugin-transform-object-assign)\/?$/
|
|
)
|
|
) {
|
|
writeFileSync(path.join(dir, "LICENSE"), LICENSE);
|
|
}
|
|
});
|
|
|
|
shell.ls("-d", "./eslint/*/").forEach(dir => {
|
|
if (!dir.match(/.*eslint\/(babel-eslint-plugin)\/?$/)) {
|
|
writeFileSync(path.join(dir, "LICENSE"), LICENSE);
|
|
}
|
|
});
|