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

Mark and protect local commits?

From
Nnorbert.nemec <norbert.nemec@native-instruments.de>
Date
Jan 9, 2012, 08:29 UTC
Message-ID
<jee8ii$6ft$1@dough.gmane.org>
Hi there,
I have often wished that there were ways to
a) protect certain commits from leaving the local repository
b) mark commits that have already left the local repository
To be more specific:

a) Sometimes, I try out certain experimental features and want to make sure they don't accidentally end up out in the wild. If there were a flag to explicitly mark them "private", any non-local operation (push, pull, etc) on these commits could create an error message.

b) For history-rewriting operations, it is important to know which commits are out in the wild and which are not. In a "push"-setup working copy, git should be able to keep track of this. Any newly created commit would be marked as "unpublished" and the mark would be removed when the commit is pushed. Any history-rewriting would be prevented on published commits.

Has anyone else thought along these lines?

Greetings, Norbert

Next: Michael Haggerty
Message 1 of 2 in “Mark and protect local commits?”
  1. norbert.nemecJan 9, 2012
  2. Michael HaggertyJan 9, 2012

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.