This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Pushing a git note fails.


Jim Meyering <jim@meyering.net> writes:

> +	refs/notes/*,delete)
> +		# delete note
> +		if [ "$allowdeletenote" != "true" ]; then
> +			echo '*** Deleting a note is not allowed' \
> +			    'in this repository' >&2
> +			exit 1
> +		fi
> +		;;

That will trigger only when someone is trying to delete an entire
notes namespace, like refs/notes/commits.  Deleting a note within
the namespace does not mean deleting the ref and therefore would
not cause this code to run.  refs/notes/commits normally refers
to a commit object whose tree contains one blob for each note.
Deleting notes from there just adds another commit object with a
smaller tree; the previous notes remain in the commit history.
Thus, edits and deletions of notes can and should be fast-forward
pushed.

(It is apparently possible to make a ref in refs/notes/* refer
directly to a tree, rather than to a commit; but I don't think
you want to do that in glibc.git.)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]