Package: mini-dinstall
Version: 0.6.25
Severity: wishlist
Tags: patch

Hi Christoph,
attached patch allows (as you know) per distribution keyrings. Please
apply.
 -- Guido
>From 1b3c7277683e9588d88aa8e215f3b91624e04318 Mon Sep 17 00:00:00 2001
From: Guido Guenther <[EMAIL PROTECTED]>
Date: Fri, 29 Aug 2008 19:41:00 +0200
Subject: [PATCH] allow keyrings and extra_keyrings per repository

this allows for fine grained permissions, like key 0x... is only allowed to
upload into the experimental archive.
---
 mini-dinstall |   14 +++++++++++---
 1 files changed, 11 insertions(+), 3 deletions(-)

diff --git a/mini-dinstall b/mini-dinstall
index 08f1ffc..063967e 100755
--- a/mini-dinstall
+++ b/mini-dinstall
@@ -365,6 +365,8 @@ class DistOptionHandler:
         self._optionmap['experimental_release'] = ['bool', 0]
         self._optionmap['release_description'] = ['str', None]
         self._optionmap['release_signscript'] = ['str', None]
+        self._optionmap['keyrings'] = ['list', None]
+        self._optionmap['extra_keyrings'] = ['list', None]
 
     def get_option_map(self, dist):
         ret = self._distributions[dist]
@@ -382,9 +384,10 @@ class DistOptionHandler:
             return self._configp.getint(dist, key)
         elif type == 'str':
             return self._configp.get(dist, key)
+	elif type == 'list':
+            return re.split(', ?', self._configp.get(dist, key))
         elif type == 'bool':
             return self._configp.getboolean(dist, key)
-
         assert(None)
             
 
@@ -711,8 +714,13 @@ class ArchiveDir:
             self.__dict__['_' + key] = configdict[key]
         do_mkdir(dir)
         self._batch_mode = batch_mode
-        self._keyrings = keyrings
-        if not extra_keyrings is None :
+        if configdict['keyrings']:
+            self._keyrings = configdict['keyrings']
+        else:
+            self._keyrings = keyrings
+	if configdict['extra_keyrings']:
+            self._extra_keyrings = configdict['extra_keyrings']
+        elif extra_keyrings:
             self._extra_keyrings = extra_keyrings
         else:
             self._extra_keyrings = []
-- 
1.5.6.3

Reply via email to