protect branches against deletion from remote

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

If you try to delete a local branch "feature" which is not merged into another branch, you will get the following warning:

. error: The branch 'feature' is not fully merged.
. If you are sure you want to delete it, run 'git branch -D feature'.

If a local branch is worth to be protected in such a way, why not the remote tracking one:

$ git push origin :feature

no warning, just deleted.

Well i can set "receive.denyDeletes" on the remote repository, but this completely removes the ability to delete remote branches.

How to achieve a similar behavior as with local branches?

(BTW. with "git push . :feature" it is also possible to force deletion of local, unmerged branches)

Best regards
Henning

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]