class Git::ExecutionContext::Repository

Execution context for repository-bound git commands

Manages the git environment for commands that operate within an existing repository — setting ‘GIT_DIR`, `GIT_WORK_TREE`, `GIT_INDEX_FILE`, and `GIT_SSH` — and prepending `–git-dir` / `–work-tree` to every git invocation via {#global_opts}.

### Construction

Use {.from_hash} to build from a configuration hash:

context = Git::ExecutionContext::Repository.from_hash(repository: '/repo/.git', ...)

@example Build from a configuration hash

context = Git::ExecutionContext::Repository.from_hash(
  repository: '/path/to/.git',
  working_directory: '/path/to'
)

@api private