INNER CODE UNIT · TypeScript
gitChildEnv
EndBug/add-and-commit · src/main.ts:32
function gitChildEnv(extra: NodeJS.ProcessEnv = {}): NodeJS.ProcessEnv {
const env: NodeJS.ProcessEnv = {...process.env, ...extra};
if (!getInput('allow_unsafe_git_protocols', true)) {
env.GIT_ALLOW_PROTOCOL = 'https:http:ssh:file:git';
env.GIT_PROTOCOL_FROM_USER = '0';
}
return env;
}
function parseGitArgs(string: string) {
return matchGitArgs(string, {
allowUnsafeGitProtocols: getInput('allow_unsafe_git_protocols', true),
});
}
const exitErrors: Error[] = [];
safeInfo(`Running in ${baseDir}`);