~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/config.py

  • Committer: Robert Collins
  • Date: 2005-10-14 04:54:03 UTC
  • mto: This revision was merged to the branch mainline in revision 1456.
  • Revision ID: robertc@lifelesslap.robertcollins.net-20051014045403-321deeebf084406f
allow global overriding of signature policy to force checking, or (pointless but allowed) to set auto checking

Show diffs side-by-side

added added

removed removed

Lines of Context:
143
143
 
144
144
    def _string_to_signature_policy(self, signature_string):
145
145
        """Convert a string to a signing policy."""
 
146
        if signature_string.lower() == 'check-available':
 
147
            return CHECK_IF_POSSIBLE
146
148
        if signature_string.lower() == 'ignore':
147
149
            return CHECK_NEVER
 
150
        if signature_string.lower() == 'require':
 
151
            return CHECK_ALWAYS
148
152
        raise errors.BzrError("Invalid signatures policy '%s'"
149
153
                              % signature_string)
150
154