Skip to main content

git_command_in

Function git_command_in 

Source
pub fn git_command_in(cwd: &Path) -> Command
Expand description

Build a git command that runs in cwd.

Every Fallow-owned Git process starts here:

  • The ambient repository-state environment is cleared.
  • Stdin is closed. Long-lived embedders keep protocol stdin open, which Git for Windows can inherit and hold.
  • Inside a deregistered base snapshot, which holds an untrusted commit, the command gets a GIT_DIR that does not exist, so Git finds no repository.
  • safe.bareRepository=explicit stops Git from using a directory shaped as a bare repository that it finds on its own. Checkouts, their subdirectories and linked worktrees are not affected.