From 8274e564025c3a8a83f09bf1cc6c9760fcc72a2a Mon Sep 17 00:00:00 2001 From: Jack Steam Date: Fri, 12 Jun 2020 14:35:21 -0500 Subject: [PATCH] Fix npm scripts --- package.json | 8 +++-- pnpm-lock.yaml | 91 ++++++++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 93 insertions(+), 6 deletions(-) diff --git a/package.json b/package.json index 1bf0361..2efbf83 100644 --- a/package.json +++ b/package.json @@ -28,21 +28,22 @@ "types" ], "scripts": { - "build": "run-s build:clean build:dev build:types", + "build": "run-s build:clean build:pro build:types build:copy", "build:dev": "rollup -c --environment NODE_ENV:development", "build:pro": "rollup -c --environment NODE_ENV:production", "build:testExtension": "rm -rf tests/e2e/extension-build && rollup -c tests/e2e/extension-src/rollup.config.js", "build:types": "tsc -p tsconfig.d.json", "build:watch": "npm run build:dev -- -w", "build:clean": "rm -rf lib types", - "prepublishOnly": "run-s build:pro build:types", + "build:copy": "copyfiles -u 1 src/*.d.ts types", + "prepublishOnly": "npm run build", "postpublish": "rm -rf node_modules package-lock.json && pnpm i", "start": "run-p build:watch test:watch", "test": "run-s test:quick test:e2e", "test:e2e": "run-s build:testExtension && jest e2e", "test:quick": "jest --testPathIgnorePatterns=e2e", "test:watch": "jest --testPathIgnorePatterns=e2e --watch", - "preversion": "run-s test:quick" + "preversion": "npm run test:quick" }, "dependencies": { "@types/chrome": "0.0.99", @@ -61,6 +62,7 @@ "@typescript-eslint/eslint-plugin": "^2.23.0", "@typescript-eslint/parser": "^2.23.0", "chrome-promise": "^3.0.5", + "copyfiles": "^2.3.0", "delay": "^4.3.0", "eslint": "^6.8.0", "eslint-plugin-jest": "^23.8.2", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 81f83fa..2faed59 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -14,6 +14,7 @@ devDependencies: '@typescript-eslint/eslint-plugin': 2.23.0_2510d86781fe783b47b58303c18a0d9b '@typescript-eslint/parser': 2.23.0_eslint@6.8.0+typescript@3.8.3 chrome-promise: 3.0.5 + copyfiles: 2.3.0 delay: 4.3.0 eslint: 6.8.0 eslint-plugin-jest: 23.8.2_eslint@6.8.0+typescript@3.8.3 @@ -1677,6 +1678,18 @@ packages: node: '>=0.10.0' resolution: integrity: sha1-Z29us8OZl8LuGsOpJP1hJHSPV40= + /copyfiles/2.3.0: + dependencies: + glob: 7.1.6 + minimatch: 3.0.4 + mkdirp: 1.0.4 + noms: 0.0.0 + through2: 2.0.5 + yargs: 15.3.1 + dev: true + hasBin: true + resolution: + integrity: sha512-73v7KFuDFJ/ofkQjZBMjMBFWGgkS76DzXvBMUh7djsMOE5EELWtAO/hRB6Wr5Vj5Zg+YozvoHemv0vnXpqxmOQ== /core-js/3.4.1: dev: true requiresBuild: true @@ -3022,6 +3035,10 @@ packages: optional: true resolution: integrity: sha512-umZHcSrwlDHo2TGMXv0DZ8dIUGunZ2Iv68YZnrmCiBPkZ4aaOhtv7pXJKeki9k3qJ3RJr0cDyitcl5wEH3AYog== + /isarray/0.0.1: + dev: true + resolution: + integrity: sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8= /isarray/1.0.0: dev: true resolution: @@ -3893,6 +3910,13 @@ packages: hasBin: true resolution: integrity: sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM= + /mkdirp/1.0.4: + dev: true + engines: + node: '>=10' + hasBin: true + resolution: + integrity: sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw== /ms/2.0.0: dev: true resolution: @@ -3971,6 +3995,13 @@ packages: optional: true resolution: integrity: sha512-SVfQ/wMw+DesunOm5cKqr6yDcvUTDl/yc97ybGHMrteNEY6oekXpNpS3lZwgLlwz0FLgHoiW28ZpmBHUDg37cw== + /noms/0.0.0: + dependencies: + inherits: 2.0.4 + readable-stream: 1.0.34 + dev: true + resolution: + integrity: sha1-2o69nzr51nYJGbJ9nNyAkqczKFk= /normalize-package-data/2.5.0: dependencies: hosted-git-info: 2.8.5 @@ -4178,17 +4209,17 @@ packages: node: '>=8' resolution: integrity: sha512-vpm09aKwq6H9phqRQzecoDpD8TmVyGw70qmWlyq5onxY7tqyTTFVvxMykxQSQKILBSFlbXpypIw2T1Ml7+DDtw== - /p-limit/2.2.2: + /p-limit/2.3.0: dependencies: p-try: 2.2.0 dev: true engines: node: '>=6' resolution: - integrity: sha512-WGR+xHecKTr7EbUEhyLSh5Dube9JtdiG78ufaeLxTgpudf/20KqyMioIUZJAezlTIi6evxuoUs9YXc11cU+yzQ== + integrity: sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w== /p-locate/4.1.0: dependencies: - p-limit: 2.2.2 + p-limit: 2.3.0 dev: true engines: node: '>=8' @@ -4496,6 +4527,15 @@ packages: node: '>=4' resolution: integrity: sha1-nLxoaXj+5l0WwA4rGcI3/Pbjg4k= + /readable-stream/1.0.34: + dependencies: + core-util-is: 1.0.2 + inherits: 2.0.4 + isarray: 0.0.1 + string_decoder: 0.10.31 + dev: true + resolution: + integrity: sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw= /readable-stream/2.3.7: dependencies: core-util-is: 1.0.2 @@ -5156,6 +5196,10 @@ packages: node: '>= 0.4' resolution: integrity: sha512-qFvWL3/+QIgZXVmJBfpHmxLB7xsUXz6HsUmP8+5dRaC3Q7oKUv9Vo6aMCRZC1smrtyECFsIT30PqBJ1gTjAs+g== + /string_decoder/0.10.31: + dev: true + resolution: + integrity: sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ= /string_decoder/1.1.1: dependencies: safe-buffer: 5.1.2 @@ -5321,6 +5365,13 @@ packages: dev: true resolution: integrity: sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU= + /through2/2.0.5: + dependencies: + readable-stream: 2.3.7 + xtend: 4.0.2 + dev: true + resolution: + integrity: sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ== /tmp/0.0.33: dependencies: os-tmpdir: 1.0.2 @@ -5763,6 +5814,12 @@ packages: node: '>=0.4.0' resolution: integrity: sha1-Z/4HXFwk/vOfnWX197f+dRcZaPw= + /xtend/4.0.2: + dev: true + engines: + node: '>=0.4' + resolution: + integrity: sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== /y18n/3.2.1: dev: true resolution: @@ -5786,6 +5843,15 @@ packages: dev: true resolution: integrity: sha512-H/V41UNZQPkUMIT5h5hiwg4QKIY1RPvoBV4XcjUbRM8Bk2oKqqyZ0DIEbTFZB0XjbtSPG8SAa/0DxCQmiRgzKg== + /yargs-parser/18.1.3: + dependencies: + camelcase: 5.3.1 + decamelize: 1.2.0 + dev: true + engines: + node: '>=6' + resolution: + integrity: sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ== /yargs/15.1.0: dependencies: cliui: 6.0.0 @@ -5804,6 +5870,24 @@ packages: node: '>=8' resolution: integrity: sha512-T39FNN1b6hCW4SOIk1XyTOWxtXdcen0t+XYrysQmChzSipvhBO8Bj0nK1ozAasdk24dNWuMZvr4k24nz+8HHLg== + /yargs/15.3.1: + dependencies: + cliui: 6.0.0 + decamelize: 1.2.0 + find-up: 4.1.0 + get-caller-file: 2.0.5 + require-directory: 2.1.1 + require-main-filename: 2.0.0 + set-blocking: 2.0.0 + string-width: 4.2.0 + which-module: 2.0.0 + y18n: 4.0.0 + yargs-parser: 18.1.3 + dev: true + engines: + node: '>=8' + resolution: + integrity: sha512-92O1HWEjw27sBfgmXiixJWT5hRBp2eobqXicLtPBIDBhYB+1HpwZlXmbW2luivBJHBzki+7VyCLRtAkScbTBQA== /yargs/3.32.0: dependencies: camelcase: 2.1.1 @@ -5842,6 +5926,7 @@ specifiers: '@typescript-eslint/eslint-plugin': ^2.23.0 '@typescript-eslint/parser': ^2.23.0 chrome-promise: ^3.0.5 + copyfiles: ^2.3.0 delay: ^4.3.0 eslint: ^6.8.0 eslint-plugin-jest: ^23.8.2