diff --git a/src/consts.ts b/src/consts.ts index 576ca5b4..e5f7ddbe 100644 --- a/src/consts.ts +++ b/src/consts.ts @@ -9,7 +9,11 @@ export function getNapiConfig(packageJson = 'package.json') { (platform: string) => `${platform}-musl`, ) const platforms = os - const version = packageVersion + const releaseVersion = process.env.RELEASE_VERSION + const releaseVersionWithoutPrefix = releaseVersion?.startsWith('v') + ? releaseVersion.substr(1) + : releaseVersion + const version = releaseVersionWithoutPrefix ?? packageVersion const packageName = name const binaryName = napi?.name ?? 'index'