Skip to content

Commit 35a27d7

Browse files
committed
Fix crash from node API call in env.ts
1 parent 6f16ab5 commit 35a27d7

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

src/env.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import { createEnv } from '@t3-oss/env-nextjs';
2-
import { execSync } from 'node:child_process';
32
import { z } from 'zod';
43

54
export const env = createEnv({
@@ -153,8 +152,7 @@ export const env = createEnv({
153152
? Number(process.env.UPLOAD_MAX_FILE_SIZE_MB)
154153
: 10,
155154
NEXT_PUBLIC_VERSION: process.env.APP_VERSION,
156-
NEXT_PUBLIC_GIT_SHA:
157-
process.env.GIT_SHA ?? execSync('git rev-parse HEAD', { encoding: 'utf-8' }).trim(),
155+
NEXT_PUBLIC_GIT_SHA: process.env.GIT_SHA,
158156
},
159157
/**
160158
* Run `build` or `dev` with `SKIP_ENV_VALIDATION` to skip env validation. This is especially

0 commit comments

Comments
 (0)