Skip to content

Commit

Permalink
Upgrade to TS 5.7.2 (#1394)
Browse files Browse the repository at this point in the history
Signed-off-by: Sri Krishna Paritala <skrishna@buf.build>
  • Loading branch information
srikrsna-buf authored Jan 6, 2025
1 parent a8f2f22 commit dd3fa81
Show file tree
Hide file tree
Showing 8 changed files with 94 additions and 122 deletions.
152 changes: 44 additions & 108 deletions package-lock.json

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

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,6 @@
"eslint-plugin-n": "^17.14.0",
"turbo": "^2.3.3",
"prettier": "^3.4.1",
"typescript": "5.6.3"
"typescript": "5.7.2"
}
}
10 changes: 8 additions & 2 deletions packages/connect-conformance/bin/connectconformance.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.

const { run } = require("../dist/cjs/src/conformance.js");
const { run } = require("../dist/cjs/conformance.js");
const { scripts } = require("../package.json");

run();
// Extract conformance runner version from the `generate` script
const [, version] = /conformance:(v\d+\.\d+\.\d+)/.exec(scripts.generate) ?? [
"?",
];

run(version);
8 changes: 4 additions & 4 deletions packages/connect-conformance/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@
"version": "2.0.0",
"private": true,
"type": "module",
"main": "./dist/cjs/src/index.js",
"main": "./dist/cjs/index.js",
"exports": {
".": {
"import": "./dist/esm/src/index.js",
"require": "./dist/cjs/src/index.js"
"import": "./dist/esm/index.js",
"require": "./dist/cjs/index.js"
}
},
"bin": {
Expand All @@ -19,7 +19,7 @@
"prebuild": "rm -rf ./dist/*",
"build": "npm run build:cjs && npm run build:esm",
"postbuild": "connectconformance --version",
"build:cjs": "tsc --project tsconfig.json --module commonjs --verbatimModuleSyntax false --moduleResolution node10 --outDir ./dist/cjs && echo >./dist/cjs/src/package.json '{\"type\":\"commonjs\"}'",
"build:cjs": "tsc --project tsconfig.json --module commonjs --verbatimModuleSyntax false --moduleResolution node10 --outDir ./dist/cjs && echo >./dist/cjs/package.json '{\"type\":\"commonjs\"}'",
"build:esm": "tsc --project tsconfig.json --outDir ./dist/esm",
"format": "prettier --write --ignore-unknown '.' '!dist' '!src/gen'",
"license-header": "license-header",
Expand Down
7 changes: 1 addition & 6 deletions packages/connect-conformance/src/conformance.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,8 @@ import * as tar from "tar-stream";
import { pipeline } from "node:stream/promises";
import { Readable } from "node:stream";
import { execFileSync } from "node:child_process";
import { scripts } from "../package.json";

export async function run() {
// Extract conformance runner version from the `generate` script
const [, version] = /conformance:(v\d+\.\d+\.\d+)/.exec(scripts.generate) ?? [
"?",
];
export async function run(version: string) {
const { archive, bin } = getArtifactNameForEnv(version);
const tempDir = getTempDir(version);
const binPath = joinPath(tempDir, bin);
Expand Down
2 changes: 1 addition & 1 deletion packages/example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,6 @@
"@bufbuild/buf": "^1.47.2",
"@bufbuild/protoc-gen-es": "^2.2.2",
"esbuild": "^0.19.8",
"typescript": "^5.6.3"
"typescript": "^5.7.2"
}
}
13 changes: 13 additions & 0 deletions packages/typescript-compat/v5.6.x/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"name": "ts5.6",
"private": true,
"scripts": {
"test": "node_modules/.bin/tsc --outDir dist"
},
"dependencies": {
"@connectrpc/connect-conformance": "*",
"@connectrpc/example": "*",
"@types/node": "22.10.1",
"typescript": "5.6.x"
}
}
Loading

0 comments on commit dd3fa81

Please sign in to comment.