Protecting the main branch from accidental check-ins
Sometimes you may start working on the main branch unaware without creating a child branch first. You get in trouble if your dirty changesets are used by others.
A good solution to protect the main branch from accidental check-ins is to deny users the check-in right on main branches. To perform a check in from their child branches they will have to log in as a different user (as an 'integrator').
The problem is that it is cumbersome. You have to run the Plastic SCM client configuration wizard to log in as an 'integrator' and then remember to switch back to your standard user after your check-in is finished.
IMHO it would be better if Plastic SCM allowed you to use different user credentials when you are trying to do something you have no permission to do. E.g. you try to merge your changes into the main branch. You have no permission, so Plastic SCM asks you to provide a different user name and password to perform this single operation.
-
Carlos commented
@Mario The idea is to have two client.conf.template files and depending on your selection on a menu, login as "userA" or "userB".
I can send you the template files and a script to switch from one user to another. You can reach me at:
calba at codicesoftware dot com -
Mariusz Schimke commented
@Carlos No, I haven't tried that yet. Is there a description how to do that? Thanks.
-
Carlos commented
HI,
Have you considered using two different "client.conf" and create a direct access menu entry?
You can switch from one to another when necessary -
Geoff commented
I agree with Mario's comment as an interim solution, however:
Perhaps a per-branch option to warn against checking in.
Often this action is perfectly valid, eg check-in after merge.
Also, you need to remember that in small shops such as ours there is no separate integrator role. -
Mariusz Schimke commented
Or, if the solution I proposed is too time consuming to implement now, it would be enough to force the user to confirm every check-in into the main branch by showing a message box (with a possibility to switch it off in the application settings).