Forbid uncommits over the network

John Arbash Meinel john at arbash-meinel.com
Fri May 8 16:08:00 BST 2009


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1


...

>>
>> The easiest would perhaps be to add a '--disallow-uncommit' 
>> option, or such, to the Bazaar smart server.
>>
>> I think that *local* uncommits are a nice feature. But it should 
>> be possible to configure a central repository in a way that a 
>> revision is immutable once pushed or committed to it. This might 
>> lead to a conflicting situation when a user locally uncommits 
>> beyond a revision that already has been sent to such a server. 
>> Maybe a warning could be displayed in such a case. 
>>
>> What are your thoughts on this?
> You can set the "append_revisions_only" setting in the branches' config
> to disallow revisions being removed from the mainline. This also
> prevents uncommits I think (or at least it should).
> 
> Cheers,
> 
> Jelmer

I'll just mention that:

bzr push
bzr uncommit
bzr commit
bzr push --overwrite

is 100% identical on the remote side to doing 'bzr uncommit bzr+ssh://...'

There are *many* ways to cause a remote branch to have its ancestry
changed. I know we have 'append_revisions_only' which certainly has
implications for 'bzr push', but I'm pretty sure 'bzr push --overwrite'
is the "I know what I'm doing, get out of my way" flag.

An even if we had a way to be more strict in the smart server, you would
have to disable "sftp://" and "nosmart+bzr+ssh://" and any sort of
direct access with a non-conforming bzr client (we want to get to the
point where we can disable Vfs access via the smart server, we just
aren't quite there yet). I'm sure someone could track down all the edge
cases if they wanted.

I *do* think it is useful to have a way to help enforce a policy like
"you shouldn't remove revisions from this branch", though generally
you'll often need a backdoor "unbreakme" ability.

John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkoEStAACgkQJdeBCYSNAAOWGgCgpfqoF9f7Uz+lDdnvt7SVxbC8
H3UAoLrIjT2LMajo+tS7dPsFcHgcnpNg
=3eRB
-----END PGP SIGNATURE-----



More information about the bazaar mailing list