
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="3a421f0b-ac5a-58d5-98d2-6072cbb2167e")}catch(e){}}();
const GIT_REPOSITORY_ENV_KEYS = new Set([
    "GIT_DIR",
    "GIT_WORK_TREE",
    "GIT_COMMON_DIR",
    "GIT_INDEX_FILE",
    "GIT_OBJECT_DIRECTORY",
    "GIT_ALTERNATE_OBJECT_DIRECTORIES",
    "GIT_PREFIX",
]);
export function createGitProcessEnv(overrides = {}) {
    const sanitized = {};
    for (const [key, value] of Object.entries(process.env)) {
        // Prevent parent git hook context from hijacking repository-scoped git commands.
        if (GIT_REPOSITORY_ENV_KEYS.has(key)) {
            continue;
        }
        sanitized[key] = value;
    }
    return {
        ...sanitized,
        ...overrides,
    };
}
//# sourceMappingURL=git-process-env.js.map
//# debugId=3a421f0b-ac5a-58d5-98d2-6072cbb2167e
