From 63f8c56605448fc617921c0437811f22e64b8fe4 Mon Sep 17 00:00:00 2001 From: Arnaud Brousseau Date: Wed, 13 Dec 2023 14:42:09 -0800 Subject: [PATCH] Add version.ts to http package --- packages/http/package.json | 1 + packages/http/src/index.ts | 2 ++ packages/http/src/version.ts | 1 + 3 files changed, 4 insertions(+) create mode 100644 packages/http/src/version.ts diff --git a/packages/http/package.json b/packages/http/package.json index 17c3d6574..024b781e9 100644 --- a/packages/http/package.json +++ b/packages/http/package.json @@ -38,6 +38,7 @@ "access": "public" }, "scripts": { + "preinstall": "node -p \"'export const VERSION = ' + JSON.stringify(require('./package.json').version) + ';'\" > src/version.ts", "prepublishOnly": "pnpm -w run clean-all && pnpm -w run build-all", "build": "rollup -c", "clean": "rimraf ./dist ./.cache", diff --git a/packages/http/src/index.ts b/packages/http/src/index.ts index 41bef6d35..3ed7fd521 100644 --- a/packages/http/src/index.ts +++ b/packages/http/src/index.ts @@ -20,3 +20,5 @@ const PublicApiService = TurnkeyApi; export { PublicApiService }; export { sealAndStampRequestBody } from "./base"; + +export { VERSION } from "./version"; diff --git a/packages/http/src/version.ts b/packages/http/src/version.ts new file mode 100644 index 000000000..be0095450 --- /dev/null +++ b/packages/http/src/version.ts @@ -0,0 +1 @@ +export const VERSION = "2.5.1";