From: Junio C Hamano Date: Thu, 21 Jan 2016 00:06:01 GMT Subject: Re: [PATCH 2/2] sh-setup: make require_clean_work_tree() work on orphan branches Message-ID: In-Reply-To: <1448376345-27339-2-git-send-email-szeder@ira.uka.de> SZEDER Gábor writes: > git-sh-setup's require_clean_work_tree() always exits with error on an > orphan branch, even when the index and worktree are both clean. Ah, I just sent a review on 1/2 as I found it was not commented on by anybody, but re-reading this sentence (and subsequent review of this 2/2) makes it clear this is not a good idea. By definition, the index immediately after creating and getting on an orphan branch is not clean [*1*]. I'll move the topic from "Needs review" to "Will discard" pile in my tree. Sorry for the noise. [Footnote] *1* Roughly speaking, if "git commit" (no arguments) to record the state of the index succeeds without "--allow-empty", your index is dirty with respect to HEAD.