diff --git a/.gitignore b/.gitignore index 3cd00b71..e560a39a 100644 --- a/.gitignore +++ b/.gitignore @@ -85,3 +85,4 @@ version.js deployment/* *.zip +.turbo diff --git a/package-lock.json b/package-lock.json index 4c623b7d..67bcf393 100644 --- a/package-lock.json +++ b/package-lock.json @@ -30,6 +30,7 @@ "progress": "^2.0.3", "semver": "^7.3.2", "swagger-tools": "^0.10.4", + "turbo": "^1.10.15", "unzip-stream": "^0.3.0", "uri-template-lite": "^20.5.0", "wait-port": "^0.2.2" @@ -21083,6 +21084,94 @@ "node": "*" } }, + "node_modules/turbo": { + "version": "1.10.15", + "resolved": "https://registry.npmjs.org/turbo/-/turbo-1.10.15.tgz", + "integrity": "sha512-mKKkqsuDAQy1wCCIjCdG+jOCwUflhckDMSRoeBPcIL/CnCl7c5yRDFe7SyaXloUUkt4tUR0rvNIhVCcT7YeQpg==", + "bin": { + "turbo": "bin/turbo" + }, + "optionalDependencies": { + "turbo-darwin-64": "1.10.15", + "turbo-darwin-arm64": "1.10.15", + "turbo-linux-64": "1.10.15", + "turbo-linux-arm64": "1.10.15", + "turbo-windows-64": "1.10.15", + "turbo-windows-arm64": "1.10.15" + } + }, + "node_modules/turbo-darwin-64": { + "version": "1.10.15", + "resolved": "https://registry.npmjs.org/turbo-darwin-64/-/turbo-darwin-64-1.10.15.tgz", + "integrity": "sha512-Sik5uogjkRTe1XVP9TC2GryEMOJCaKE2pM/O9uLn4koQDnWKGcLQv+mDU+H+9DXvKLnJnKCD18OVRkwK5tdpoA==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/turbo-darwin-arm64": { + "version": "1.10.15", + "resolved": "https://registry.npmjs.org/turbo-darwin-arm64/-/turbo-darwin-arm64-1.10.15.tgz", + "integrity": "sha512-xwqyFDYUcl2xwXyGPmHkmgnNm4Cy0oNzMpMOBGRr5x64SErS7QQLR4VHb0ubiR+VAb8M+ECPklU6vD1Gm+wekg==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/turbo-linux-64": { + "version": "1.10.15", + "resolved": "https://registry.npmjs.org/turbo-linux-64/-/turbo-linux-64-1.10.15.tgz", + "integrity": "sha512-dM07SiO3RMAJ09Z+uB2LNUSkPp3I1IMF8goH5eLj+d8Kkwoxd/+qbUZOj9RvInyxU/IhlnO9w3PGd3Hp14m/nA==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/turbo-linux-arm64": { + "version": "1.10.15", + "resolved": "https://registry.npmjs.org/turbo-linux-arm64/-/turbo-linux-arm64-1.10.15.tgz", + "integrity": "sha512-MkzKLkKYKyrz4lwfjNXH8aTny5+Hmiu4SFBZbx+5C0vOlyp6fV5jZANDBvLXWiDDL4DSEAuCEK/2cmN6FVH1ow==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/turbo-windows-64": { + "version": "1.10.15", + "resolved": "https://registry.npmjs.org/turbo-windows-64/-/turbo-windows-64-1.10.15.tgz", + "integrity": "sha512-3TdVU+WEH9ThvQGwV3ieX/XHebtYNHv9HARHauPwmVj3kakoALkpGxLclkHFBLdLKkqDvmHmXtcsfs6cXXRHJg==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/turbo-windows-arm64": { + "version": "1.10.15", + "resolved": "https://registry.npmjs.org/turbo-windows-arm64/-/turbo-windows-arm64-1.10.15.tgz", + "integrity": "sha512-l+7UOBCbfadvPMYsX08hyLD+UIoAkg6ojfH+E8aud3gcA1padpjCJTh9gMpm3QdMbKwZteT5uUM+wyi6Rbbyww==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "win32" + ] + }, "node_modules/type": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/type/-/type-1.0.1.tgz", @@ -38573,6 +38662,55 @@ "safe-buffer": "^5.0.1" } }, + "turbo": { + "version": "1.10.15", + "resolved": "https://registry.npmjs.org/turbo/-/turbo-1.10.15.tgz", + "integrity": "sha512-mKKkqsuDAQy1wCCIjCdG+jOCwUflhckDMSRoeBPcIL/CnCl7c5yRDFe7SyaXloUUkt4tUR0rvNIhVCcT7YeQpg==", + "requires": { + "turbo-darwin-64": "1.10.15", + "turbo-darwin-arm64": "1.10.15", + "turbo-linux-64": "1.10.15", + "turbo-linux-arm64": "1.10.15", + "turbo-windows-64": "1.10.15", + "turbo-windows-arm64": "1.10.15" + } + }, + "turbo-darwin-64": { + "version": "1.10.15", + "resolved": "https://registry.npmjs.org/turbo-darwin-64/-/turbo-darwin-64-1.10.15.tgz", + "integrity": "sha512-Sik5uogjkRTe1XVP9TC2GryEMOJCaKE2pM/O9uLn4koQDnWKGcLQv+mDU+H+9DXvKLnJnKCD18OVRkwK5tdpoA==", + "optional": true + }, + "turbo-darwin-arm64": { + "version": "1.10.15", + "resolved": "https://registry.npmjs.org/turbo-darwin-arm64/-/turbo-darwin-arm64-1.10.15.tgz", + "integrity": "sha512-xwqyFDYUcl2xwXyGPmHkmgnNm4Cy0oNzMpMOBGRr5x64SErS7QQLR4VHb0ubiR+VAb8M+ECPklU6vD1Gm+wekg==", + "optional": true + }, + "turbo-linux-64": { + "version": "1.10.15", + "resolved": "https://registry.npmjs.org/turbo-linux-64/-/turbo-linux-64-1.10.15.tgz", + "integrity": "sha512-dM07SiO3RMAJ09Z+uB2LNUSkPp3I1IMF8goH5eLj+d8Kkwoxd/+qbUZOj9RvInyxU/IhlnO9w3PGd3Hp14m/nA==", + "optional": true + }, + "turbo-linux-arm64": { + "version": "1.10.15", + "resolved": "https://registry.npmjs.org/turbo-linux-arm64/-/turbo-linux-arm64-1.10.15.tgz", + "integrity": "sha512-MkzKLkKYKyrz4lwfjNXH8aTny5+Hmiu4SFBZbx+5C0vOlyp6fV5jZANDBvLXWiDDL4DSEAuCEK/2cmN6FVH1ow==", + "optional": true + }, + "turbo-windows-64": { + "version": "1.10.15", + "resolved": "https://registry.npmjs.org/turbo-windows-64/-/turbo-windows-64-1.10.15.tgz", + "integrity": "sha512-3TdVU+WEH9ThvQGwV3ieX/XHebtYNHv9HARHauPwmVj3kakoALkpGxLclkHFBLdLKkqDvmHmXtcsfs6cXXRHJg==", + "optional": true + }, + "turbo-windows-arm64": { + "version": "1.10.15", + "resolved": "https://registry.npmjs.org/turbo-windows-arm64/-/turbo-windows-arm64-1.10.15.tgz", + "integrity": "sha512-l+7UOBCbfadvPMYsX08hyLD+UIoAkg6ojfH+E8aud3gcA1padpjCJTh9gMpm3QdMbKwZteT5uUM+wyi6Rbbyww==", + "optional": true + }, "type": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/type/-/type-1.0.1.tgz", diff --git a/package.json b/package.json index af688250..24cdb9b6 100644 --- a/package.json +++ b/package.json @@ -14,6 +14,9 @@ "SEARCH_IMAGE": "opensearchproject/opensearch:1.2.4" }, "scripts": { + "turbo:build": "turbo run build", + "turbo:ci:version": "turbo run ci:version", + "turbo:ci:publish": "turbo run ci:publish", "pull:open-search": "docker pull ${npm_package_config_SEARCH_IMAGE}", "start:open-search": "docker run -p 9200:9200 -p 9300:9300 -e \"ES_JAVA_OPTS=-Xms1g -Xmx1g\" -e \"discovery.type=single-node\" -e \"plugins.security.disabled=true\" \"${npm_package_config_SEARCH_IMAGE}\"", "hmm": "echo mountainpass-addressr-${npm_package_version}.tgz", @@ -106,7 +109,9 @@ "check-licenses": "license-checker --production --onlyAllow 'MIT;Apache-2.0;ISC;Custom: http://github.com/substack/node-bufferlist;Unlicense;BSD-2-Clause;BSD-3-Clause;WTFPL;0BSD;MIT*' --summary", "pre-commit": "lint-staged && npm run check-licenses", "test:performance": "k6 run --out csv=target/stress.csv test/k6/script.js", - "add-changeset": "changeset add --open" + "add-changeset": "changeset add --open", + "ci:version": "[ \"$CI\" = true ] && changeset version || echo \"Dry run: changeset version\"", + "ci:publish": "[ \"$CI\" = true ] && changeset publish || echo \"Dry run: changeset publish\"" }, "bin": { "addressr-loader": "lib/bin/addressr-loader.js", @@ -156,6 +161,7 @@ "progress": "^2.0.3", "semver": "^7.3.2", "swagger-tools": "^0.10.4", + "turbo": "^1.10.15", "unzip-stream": "^0.3.0", "uri-template-lite": "^20.5.0", "wait-port": "^0.2.2" @@ -236,4 +242,4 @@ "pre-commit": "npm run pre-commit" } } -} +} \ No newline at end of file diff --git a/turbo.json b/turbo.json new file mode 100644 index 00000000..69650bf6 --- /dev/null +++ b/turbo.json @@ -0,0 +1,40 @@ +{ + "$schema": "https://turbo.build/schema.json", + "pipeline": { + "build": { + "dependsOn": [ + "^build" + ], + "inputs": [ + "src/**/*" + ], + "outputs": [ + "lib/**" + ] + }, + "ci:build": { + "dependsOn": [ + "build" + ], + "inputs": [ + "src/**/*" + ], + "outputs": [ + "lib/**" + ] + }, + "ci:version": { + "dependsOn": [ + "build" + ] + }, + "ci:publish": { + "dependsOn": [ + "build" + ] + } + }, + "globalDependencies": [ + ".babelrc" + ] +} \ No newline at end of file