Skip to content

Commit

Permalink
Bump to v2.1.3 - Fix postinstall error ts-node not found in non-dev…
Browse files Browse the repository at this point in the history
… installs (#991)
  • Loading branch information
wipfli committed Feb 12, 2022
1 parent 0b6f7ad commit b65fbdd
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 8 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,13 @@
### 🐞 Bug fixes

- *...Add new stuff here...*

## 2.1.3

### 🐞 Bug fixes

- Fix postinstall `ts-node` error on non-dev installs (#900)

## 2.1.2

### Features and improvements
Expand Down
10 changes: 6 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 3 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "maplibre-gl",
"description": "BSD licensed community fork of mapbox-gl, a WebGL interactive maps library",
"version": "2.1.2",
"version": "2.1.3",
"main": "dist/maplibre-gl.js",
"style": "dist/maplibre-gl.css",
"license": "BSD-3-Clause",
Expand All @@ -24,7 +24,6 @@
"earcut": "^2.2.3",
"geojson-vt": "^3.2.1",
"gl-matrix": "^3.4.3",
"husky": "^7.0.4",
"murmurhash-js": "^1.0.0",
"pbf": "^3.2.1",
"potpack": "^1.0.2",
Expand Down Expand Up @@ -95,6 +94,7 @@
"eslint-plugin-react": "^7.28.0",
"gl": "^5.0.0",
"glob": "^7.2.0",
"husky": "^7.0.4",
"is-builtin-module": "^3.1.0",
"jest": "^27.5.1",
"jest-canvas-mock": "^2.3.1",
Expand Down Expand Up @@ -171,8 +171,7 @@
"codegen": "npm run generate-style-code && npm run generate-struct-arrays && npm run generate-style-spec && npm run generate-shaders",
"benchmark": "node --loader ts-node/esm --experimental-specifier-resolution=node test/bench/run-benchmarks.ts",
"gl-stats": "node --loader ts-node/esm --experimental-specifier-resolution=node test/bench/gl-stats.ts",
"postinstall": "npm run codegen && npm run generate-query-test-fixtures",
"prepare": "husky install"
"postinstall": "node ./postinstall.js"
},
"files": [
"build/",
Expand Down
5 changes: 5 additions & 0 deletions postinstall.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import {execSync} from 'child_process';

if (process.env.NODE_ENV !== 'production') {
execSync('npm run codegen && npm run generate-query-test-fixtures && husky install');
}

0 comments on commit b65fbdd

Please sign in to comment.