Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I restrict commits to a specific branch in Mercurial?

I'm essentially seeking for a way to manage write permissions to specific branches.

This can be either before committing (local), or after committing but before pushing (remote).

I need to protect certain branches from being written to in order to enforce a workflow where the release branch can only be edited by some.

like image 878
dukeofgaming Avatar asked Sep 06 '25 03:09

dukeofgaming


2 Answers

Enabled and properly configured ACL Extension can be an answer in your case

like image 171
Lazy Badger Avatar answered Sep 07 '25 22:09

Lazy Badger


ACL Extension would do it

regarding branches however:

You cannot limit read access to a subset of a repository with a read rule and a file condition: any user who has access to a repository can read all of it and its full history. 

But you can disallow push.

like image 27
Nadir Avatar answered Sep 07 '25 22:09

Nadir