git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Prevent force updating of the current branch
@ 2011-08-20 21:49 Conrad Irwin
  2011-08-20 21:49 ` [PATCH 1/2] Prevent force-updating " Conrad Irwin
  2011-08-20 21:49 ` [PATCH 2/2] Show interpreted branch name in error messages Conrad Irwin
  0 siblings, 2 replies; 5+ messages in thread
From: Conrad Irwin @ 2011-08-20 21:49 UTC (permalink / raw)
  To: git; +Cc: gitster

I noticed when trying to improve the user-experience of creating
ambiguous branches [1] that there are insufficient checks to safeguard
git-branch -M and git-checkout -B from over-writing the current branch.

Conrad

[1] http://thread.gmane.org/gmane.comp.version-control.git/179503

---
 branch.c                   |   34 ++++++++++++++++++++++++----------
 branch.h                   |    8 ++++++++
 builtin/branch.c           |    6 +-----
 builtin/checkout.c         |   12 +++---------
 t/t2018-checkout-branch.sh |   17 +++++++++++++++++
 t/t3200-branch.sh          |   12 ++++++++++++
 6 files changed, 65 insertions(+), 24 deletions(-)

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-08-23 19:20 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-08-20 21:49 [PATCH] Prevent force updating of the current branch Conrad Irwin
2011-08-20 21:49 ` [PATCH 1/2] Prevent force-updating " Conrad Irwin
2011-08-23 18:20   ` Junio C Hamano
2011-08-23 19:20     ` Conrad Irwin
2011-08-20 21:49 ` [PATCH 2/2] Show interpreted branch name in error messages Conrad Irwin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).