import { Effect, FileSystem } from "effect"; import { CliProjectEnvParseError } from "./errors.ts"; import { type ResolvedCliConfigValue } from "./lib/resolve.ts"; import { type CliProjectPaths } from "./paths.ts"; export interface CliProjectEnvironment { readonly paths: CliProjectPaths; readonly values: Readonly>; readonly loadedPaths: ReadonlyArray; readonly sources: Readonly>; } /** Parse one explicit dotenv file without applying ambient or project-local precedence. */ export declare const loadDotEnvFile: (path: string) => Effect.Effect, CliProjectEnvParseError | import("effect/PlatformError").PlatformError, FileSystem.FileSystem>; export interface LoadCliProjectEnvironmentOptions { readonly cwd: string; readonly baseEnv?: Readonly>; /** See {@link FindCliProjectPathsOptions.search}. */ readonly search?: boolean; /** * Skip reading/parsing `paths.envLocalPath` (`supabase/.env.local`) entirely, so a * malformed or intentionally non-test `.env.local` cannot fail config loading. Defaults * to `false`. */ readonly skipEnvLocal?: boolean; } /** Not covered by semver — exported from `@supabase/config/internal` only. */ export interface InternalResolveCliConfigOptions { /** * Opt into viper-style case-agnostic `env()` matching (`^env\((.*)\)$`). Defaults to * `false`, which requires SCREAMING_SNAKE_CASE. */ readonly goViperCompat?: boolean; } export declare const loadCliProjectEnvironment: (options: LoadCliProjectEnvironmentOptions) => Effect.Effect<{ paths: { projectRoot: string; supabaseDir: string; configPath: string; envPath: string; envLocalPath: string; }; values: Record; loadedPaths: string[]; sources: Record; } | null, CliProjectEnvParseError | import("effect/PlatformError").PlatformError, FileSystem.FileSystem | import("effect/Path").Path>; /** * Effect-typed counterpart of the plain sync `resolveCliConfigValue` in * `./lib/resolve.ts`, additionally accepting the internal-only `goViperCompat` option. * * Accepts `Pick` so a caller with only a project's env * values, not the full loaded object, can pass `{ values }` directly. */ export declare function resolveCliConfigValue(value: T, cliProjectEnv: Pick, configPath: string, options?: InternalResolveCliConfigOptions): Effect.Effect>; /** See {@link resolveCliConfigValue}'s doc comment for why `cliProjectEnv` only needs `.values`. */ export declare function resolveCliConfigSubtree(value: T, cliProjectEnv: Pick, pathPrefix: string, options?: InternalResolveCliConfigOptions): Effect.Effect>; //# sourceMappingURL=project.d.ts.map