/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/smart/branch.py

Set branch config options via a smart method.

Show diffs side-by-side

added added

removed removed

Lines of Context:
148
148
            return FailedSmartServerResponse(('TipChangeRejected', msg))
149
149
 
150
150
 
 
151
class SmartServerBranchRequestSetConfigOption(SmartServerLockedBranchRequest):
 
152
    """Set an option in the branch configuration."""
 
153
 
 
154
    def do_with_locked_branch(self, branch, value, name, section):
 
155
        if not section:
 
156
            section = None
 
157
        branch._get_config().set_option(value, name, section)
 
158
        return SuccessfulSmartServerResponse(())
 
159
 
 
160
 
151
161
class SmartServerBranchRequestSetLastRevision(SmartServerSetTipRequest):
152
162
 
153
163
    def do_tip_change_with_locked_branch(self, branch, new_last_revision_id):