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

checking for 'clean' bare repo before push

From
NKNeal Kreitzinger <nkreitzinger@gmail.com>
Date
Jun 24, 2012, 10:21 UTC
Message-ID
<js6pnt$28f$1@dough.gmane.org>

I'm being asked to provide commands to check for 'clean' state of bare repo before and after a git-push. This request is based on the notion of checking for a clean worktree (git status) before a checkout, merge, etc on a non-bare repo and checking the worktree state after such operations.

Context: Since the bare repo and non-bare clone repos in question only have branch master, and deny-non-ff is set for the bare repo, I don't think there are checks to be done before and after git-push in our case. git-gc and git-fsck could be possible, but don't seem normative for every single push. git-gc has auto configurations, and git fsck is expensive. It seems like routine git-gc obviates the need for git fsck.

Am I correct on this?

v/r, neal

Next: Junio C Hamano
Message 1 of 2 in “checking for 'clean' bare repo before push”
  1. Neal KreitzingerJun 24, 2012
  2. Junio C HamanoJun 25, 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.