Skip to content

Commit

Permalink
chore: inline the postbuild script to fix ESM support in dev builds
Browse files Browse the repository at this point in the history
Closes #3808
  • Loading branch information
B4nan committed Dec 2, 2022
1 parent 5ffa81c commit 42fa288
Show file tree
Hide file tree
Showing 14 changed files with 14 additions and 28 deletions.
3 changes: 1 addition & 2 deletions packages/better-sqlite/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@
"node": ">= 14.0.0"
},
"scripts": {
"build": "yarn clean && yarn compile && yarn copy",
"postbuild": "yarn gen-esm-wrapper dist/index.js dist/index.mjs",
"build": "yarn clean && yarn compile && yarn copy && yarn run -T gen-esm-wrapper dist/index.js dist/index.mjs",
"clean": "rimraf ./dist",
"compile": "tsc -p tsconfig.build.json",
"copy": "node ../../scripts/copy.mjs"
Expand Down
3 changes: 1 addition & 2 deletions packages/cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,7 @@
"node": ">= 14.0.0"
},
"scripts": {
"build": "yarn clean && yarn compile && yarn copy",
"postbuild": "yarn gen-esm-wrapper dist/index.js dist/index.mjs",
"build": "yarn clean && yarn compile && yarn copy && yarn run -T gen-esm-wrapper dist/index.js dist/index.mjs",
"clean": "rimraf ./dist",
"compile": "tsc -p tsconfig.build.json",
"copy": "node ../../scripts/copy.mjs"
Expand Down
3 changes: 1 addition & 2 deletions packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@
"node": ">= 14.0.0"
},
"scripts": {
"build": "yarn clean && yarn compile && yarn copy",
"postbuild": "yarn gen-esm-wrapper dist/index.js dist/index.mjs",
"build": "yarn clean && yarn compile && yarn copy && yarn run -T gen-esm-wrapper dist/index.js dist/index.mjs",
"clean": "rimraf ./dist",
"compile": "tsc -p tsconfig.build.json",
"copy": "node ../../scripts/copy.mjs"
Expand Down
3 changes: 1 addition & 2 deletions packages/entity-generator/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@
"node": ">= 14.0.0"
},
"scripts": {
"build": "yarn clean && yarn compile && yarn copy",
"postbuild": "yarn gen-esm-wrapper dist/index.js dist/index.mjs",
"build": "yarn clean && yarn compile && yarn copy && yarn run -T gen-esm-wrapper dist/index.js dist/index.mjs",
"clean": "rimraf ./dist",
"compile": "tsc -p tsconfig.build.json",
"copy": "node ../../scripts/copy.mjs"
Expand Down
3 changes: 1 addition & 2 deletions packages/knex/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@
"node": ">= 14.0.0"
},
"scripts": {
"build": "yarn clean && yarn compile && yarn copy",
"postbuild": "yarn gen-esm-wrapper dist/index.js dist/index.mjs",
"build": "yarn clean && yarn compile && yarn copy && yarn run -T gen-esm-wrapper dist/index.js dist/index.mjs",
"clean": "rimraf ./dist",
"compile": "tsc -p tsconfig.build.json",
"copy": "node ../../scripts/copy.mjs"
Expand Down
3 changes: 1 addition & 2 deletions packages/mariadb/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@
"node": ">= 14.0.0"
},
"scripts": {
"build": "yarn clean && yarn compile && yarn copy",
"postbuild": "yarn gen-esm-wrapper dist/index.js dist/index.mjs",
"build": "yarn clean && yarn compile && yarn copy && yarn run -T gen-esm-wrapper dist/index.js dist/index.mjs",
"clean": "rimraf ./dist",
"compile": "tsc -p tsconfig.build.json",
"copy": "node ../../scripts/copy.mjs"
Expand Down
3 changes: 1 addition & 2 deletions packages/migrations-mongodb/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@
"node": ">= 14.0.0"
},
"scripts": {
"build": "yarn clean && yarn compile && yarn copy",
"postbuild": "yarn gen-esm-wrapper dist/index.js dist/index.mjs",
"build": "yarn clean && yarn compile && yarn copy && yarn run -T gen-esm-wrapper dist/index.js dist/index.mjs",
"clean": "rimraf ./dist",
"compile": "tsc -p tsconfig.build.json",
"copy": "node ../../scripts/copy.mjs"
Expand Down
3 changes: 1 addition & 2 deletions packages/migrations/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@
"node": ">= 14.0.0"
},
"scripts": {
"build": "yarn clean && yarn compile && yarn copy",
"postbuild": "yarn gen-esm-wrapper dist/index.js dist/index.mjs",
"build": "yarn clean && yarn compile && yarn copy && yarn run -T gen-esm-wrapper dist/index.js dist/index.mjs",
"clean": "rimraf ./dist",
"compile": "tsc -p tsconfig.build.json",
"copy": "node ../../scripts/copy.mjs"
Expand Down
3 changes: 1 addition & 2 deletions packages/mikro-orm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@
"node": ">= 14.0.0"
},
"scripts": {
"build": "yarn clean && yarn compile && yarn copy",
"postbuild": "yarn gen-esm-wrapper dist/index.js dist/index.mjs",
"build": "yarn clean && yarn compile && yarn copy && yarn run -T gen-esm-wrapper dist/index.js dist/index.mjs",
"clean": "rimraf ./dist",
"compile": "tsc -p tsconfig.build.json",
"copy": "node ../../scripts/copy.mjs"
Expand Down
3 changes: 1 addition & 2 deletions packages/mongodb/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@
"node": ">= 14.0.0"
},
"scripts": {
"build": "yarn clean && yarn compile && yarn copy",
"postbuild": "yarn gen-esm-wrapper dist/index.js dist/index.mjs",
"build": "yarn clean && yarn compile && yarn copy && yarn run -T gen-esm-wrapper dist/index.js dist/index.mjs",
"clean": "rimraf ./dist",
"compile": "tsc -p tsconfig.build.json",
"copy": "node ../../scripts/copy.mjs"
Expand Down
3 changes: 1 addition & 2 deletions packages/mysql/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@
"node": ">= 14.0.0"
},
"scripts": {
"build": "yarn clean && yarn compile && yarn copy",
"postbuild": "yarn gen-esm-wrapper dist/index.js dist/index.mjs",
"build": "yarn clean && yarn compile && yarn copy && yarn run -T gen-esm-wrapper dist/index.js dist/index.mjs",
"clean": "rimraf ./dist",
"compile": "tsc -p tsconfig.build.json",
"copy": "node ../../scripts/copy.mjs"
Expand Down
3 changes: 1 addition & 2 deletions packages/postgresql/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@
"node": ">= 14.0.0"
},
"scripts": {
"build": "yarn clean && yarn compile && yarn copy",
"postbuild": "yarn gen-esm-wrapper dist/index.js dist/index.mjs",
"build": "yarn clean && yarn compile && yarn copy && yarn run -T gen-esm-wrapper dist/index.js dist/index.mjs",
"clean": "rimraf ./dist",
"compile": "tsc -p tsconfig.build.json",
"copy": "node ../../scripts/copy.mjs"
Expand Down
3 changes: 1 addition & 2 deletions packages/reflection/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@
"node": ">= 14.0.0"
},
"scripts": {
"build": "yarn clean && yarn compile && yarn copy",
"postbuild": "yarn gen-esm-wrapper dist/index.js dist/index.mjs",
"build": "yarn clean && yarn compile && yarn copy && yarn run -T gen-esm-wrapper dist/index.js dist/index.mjs",
"clean": "rimraf ./dist",
"compile": "tsc -p tsconfig.build.json",
"copy": "node ../../scripts/copy.mjs"
Expand Down
3 changes: 1 addition & 2 deletions packages/sqlite/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@
"node": ">= 14.0.0"
},
"scripts": {
"build": "yarn clean && yarn compile && yarn copy",
"postbuild": "yarn gen-esm-wrapper dist/index.js dist/index.mjs",
"build": "yarn clean && yarn compile && yarn copy && yarn run -T gen-esm-wrapper dist/index.js dist/index.mjs",
"clean": "rimraf ./dist",
"compile": "tsc -p tsconfig.build.json",
"copy": "node ../../scripts/copy.mjs"
Expand Down

0 comments on commit 42fa288

Please sign in to comment.