git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Introduce receive.denyDeletes

From
Shawn O. Pearce <spearce@spearce.org>
Date
Oct 30, 2008, 18:32 UTC
Message-ID
<20081030183210.GO14786@spearce.org>
In-Reply-To
<20081030191134.62455c24@perceptron>
Jan Krrrger <jk@jk.gs> wrote:
Show 5 quoted lines
> Occasionally, it may be useful to prevent branches from getting deleted from
> a centralized repository, particularly when no administrative access to the
> server is available to undo it via reflog. It also makes
> receive.denyNonFastForwards more useful if it is used for access control, since
> it prevents force-updating refs by deleting and re-creating a ref.
...
Show 8 quoted lines
>  test_expect_success \
> +	'pushing a delete should be denied with denyDeletes' '
> +	cd victim &&
> +	git config receive.denyDeletes true &&
> +	git branch extra master &&
> +	cd .. &&
> +	test -f victim/.git/refs/heads/extra &&
> +	git send-pack ./victim/.git/ :extra master && return 1
Hmm, that should be:
  test_must_fail git send-pack ./victim/.git/ :extra master
-- 
Shawn.
Previous: Jan KrügerNext: Jan Krüger
Message 2 of 8 in “Introduce receive.denyDeletes”
  1. Introduce receive.denyDeletesJan Krüger, Oct 30, 2008
  2. Shawn O. PearceOct 30, 2008
  3. Jan KrügerOct 30, 2008
  4. Junio C HamanoOct 31, 2008
  5. Shawn O. PearceOct 31, 2008
  6. Introduce receive.denyDeletesJan Krüger, Nov 1, 2008
  7. Shawn O. PearceNov 1, 2008
  8. Johannes SchindelinOct 31, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.