I have two branches in my bitbucket repository - master and dev. I want the master branch to read and clone for everyone. Write will still be restricted on master. However, the dev branch should be visible only to developers and it should stay private among developers. This branch is shared among developers who will commit and push for others. How do I enforce a branch to be private in a public repository on bitbucket?
No, this is not possible. A branch is nothing of substance in git
, it is just a "sticky note" pointing to a commit. There is no sense of "these n
commits belong to branch X
and should be private", so anyone who pulls stuff from your repository can get all your commits.
If you insist on having the development private, just fork the repository and make the fork private...
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With