diff options
author | Daniel Silverstone <daniel.silverstone@codethink.co.uk> | 2013-06-03 14:14:34 +0100 |
---|---|---|
committer | Daniel Silverstone <daniel.silverstone@codethink.co.uk> | 2013-06-03 14:14:34 +0100 |
commit | 5ecca7be5cd2caaddb61fbf2ca5caa108fbe29f2 (patch) | |
tree | ca7f7c1153301856e8a2a47fef5b7e224cb6be62 /morphlib/util.py | |
parent | 6bdc02f247b5c413d58b9b611f436f946dc3856b (diff) | |
download | morph-5ecca7be5cd2caaddb61fbf2ca5caa108fbe29f2.tar.gz |
UTIL: Update trove-id processing for hyphens
Ensure that trove-id meets the same requirements as repo aliases in terms of
naming.
Diffstat (limited to 'morphlib/util.py')
-rw-r--r-- | morphlib/util.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/morphlib/util.py b/morphlib/util.py index b509f0b0..6d7d5c4b 100644 --- a/morphlib/util.py +++ b/morphlib/util.py @@ -107,8 +107,8 @@ def combine_aliases(app): # pragma: no cover trove_host = app.settings['trove-host'] trove_ids = app.settings['trove-id'] repo_aliases = app.settings['repo-alias'] - repo_pat = r'^(?P<prefix>[a-z0-9]+)=(?P<pull>[^#]+)#(?P<push>[^#]+)$' - trove_pat = (r'^(?P<prefix>[a-z0-9]+)=(?P<path>[^#]+)#' + repo_pat = r'^(?P<prefix>[a-z][a-z0-9-]+)=(?P<pull>[^#]+)#(?P<push>[^#]+)$' + trove_pat = (r'^(?P<prefix>[a-z][a-z0-9-]+)=(?P<path>[^#]+)#' '(?P<pull>[^#]+)#(?P<push>[^#]+)$') alias_map = {} def _expand(protocol, path): |