()
| 1053 | } |
| 1054 | |
| 1055 | function loadRepoEnvDefaults() { |
| 1056 | const combined = { |
| 1057 | ...parseEnvFile(path.join(REPO_ROOT, '.env')), |
| 1058 | ...parseEnvFile(path.join(REPO_ROOT, '.env.local')), |
| 1059 | }; |
| 1060 | for (const [key, value] of Object.entries(combined)) { |
| 1061 | if (process.env[key] === undefined) { |
| 1062 | process.env[key] = value; |
| 1063 | } |
| 1064 | } |
| 1065 | } |
| 1066 | |
| 1067 | function parseEnvFile(filePath: string): Record<string, string> { |
| 1068 | if (!fs.existsSync(filePath)) { |