From fff0d0abdde6729606824688c2acac72db643e65 Mon Sep 17 00:00:00 2001 From: Jonathan Nieder Date: Thu, 15 Apr 2010 02:25:38 -0500 Subject: Document new "already-merged" rule for branch -d MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit v1.7.0-rc0~18^2 (branch -d: base the "already-merged" safety on the branch it merges with, 2009-12-29) taught ‘git branch’ a new heuristic for when it is safe to delete a branch without forcing the issue. It is safe to delete a branch "topic" without second thought if: - the branch "topic" is set up to pull from a (remote-tracking, usually) branch and is fully merged in that "upstream" branch, or - there is no branch.topic.merge configuration and branch "topic" is fully merged in the current HEAD. Update the man page to acknowledge the new rules. Signed-off-by: Jonathan Nieder Signed-off-by: Junio C Hamano --- Documentation/git-branch.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Documentation/git-branch.txt') diff --git a/Documentation/git-branch.txt b/Documentation/git-branch.txt index b3605c0ec5..60fa684b1d 100644 --- a/Documentation/git-branch.txt +++ b/Documentation/git-branch.txt @@ -63,7 +63,9 @@ way to clean up all obsolete remote-tracking branches. OPTIONS ------- -d:: - Delete a branch. The branch must be fully merged in HEAD. + Delete a branch. The branch must be fully merged in its + upstream branch, or in `HEAD` if no upstream was set with + `--track` or `--set-upstream`. -D:: Delete a branch irrespective of its merged status. -- cgit v1.2.3