Skip to main content

Module config

Module config 

Source
Expand description

Repo-level git config mutators — mirrors JSS src/handlers/git.js lines 133-150, which runs two git config invocations on every write request:

  1. git config http.receivepack true (always — so HTTP push is accepted even on repos that didn’t set this at init time).
  2. git config receive.denyCurrentBranch updateInstead (only on non-bare repos — so a push to the currently checked-out branch updates the working tree instead of being rejected).

Both invocations are idempotent; running them on every write is the JSS-chosen strategy, and we replicate it here.

Structs§

GitDir
Information about the git directory layout for a given repo path.

Functions§

apply_write_config
Apply the JSS-parity config to a repo on every write request.
find_git_dir
Inspect repo_path and determine whether it is a git repository, and if so whether it is bare.
run_git_config
Run git config --local <key> <value> with GIT_DIR set.