Home Explore Blog CI



git

2nd chunk of `Documentation/config/receive.adoc`
ec80731e9669579a476a9927b8e0fbe984148c90221549ca0000000100000827
 connection.
	With this option set, if `receive-pack` does not transmit
	any data in this phase for `receive.keepAlive` seconds, it will
	send a short keepalive packet.  The default is 5 seconds; set
	to 0 to disable keepalives entirely.

receive.unpackLimit::
	If the number of objects received in a push is below this
	limit then the objects will be unpacked into loose object
	files. However if the number of received objects equals or
	exceeds this limit then the received pack will be stored as
	a pack, after adding any missing delta bases.  Storing the
	pack from a push can make the push operation complete faster,
	especially on slow filesystems.  If not set, the value of
	`transfer.unpackLimit` is used instead.

receive.maxInputSize::
	If the size of the incoming pack stream is larger than this
	limit, then git-receive-pack will error out, instead of
	accepting the pack file. If not set or set to 0, then the size
	is unlimited.

receive.denyDeletes::
	If set to true, git-receive-pack will deny a ref update that deletes
	the ref. Use this to prevent such a ref deletion via a push.

receive.denyDeleteCurrent::
	If set to true, git-receive-pack will deny a ref update that
	deletes the currently checked out branch of a non-bare repository.

receive.denyCurrentBranch::
	If set to true or "refuse", git-receive-pack will deny a ref update
	to the currently checked out branch of a non-bare repository.
	Such a push is potentially dangerous because it brings the HEAD
	out of sync with the index and working tree. If set to "warn",
	print a warning of such a push to stderr, but allow the push to
	proceed. If set to false or "ignore", allow such pushes with no
	message. Defaults to "refuse".
+
Another option is "updateInstead" which will update the working
tree if pushing into the current branch.  This option is
intended for synchronizing working directories when one side is not easily
accessible via interactive ssh (e.g. a live web site, hence the requirement
that the working directory be clean). This mode also comes in handy when
developing inside a VM to test

Title: Git Receive Pack Configuration Options for Push Validation
Summary
Options for customizing git-receive-pack's behavior during push operations, including settings for keepalives, object unpacking, input size limits, and ref update validation, which help prevent accidental deletions, maintain repository consistency, and ensure safe push operations.