Strip unwanted prefix from git.lookaside.new messages.

This commit is contained in:
Ralph Bean 2015-02-19 15:01:04 +00:00
parent 905ae5fa76
commit 9b5b3b531d

View file

@ -156,6 +156,10 @@ def main():
hash_dir = os.path.join(module_dir, filename, checksum)
msgpath = os.path.join(name, module_dir, filename, checksum, filename)
unwanted_prefix = '/srv/cache/lookaside/pkgs/'
if msgpath.startswith(unwanted_prefix):
msgpath = msgpath[len(unwanted_prefix):]
# first test if the module really exists
git_dir = os.path.join(GITREPO, '%s.git' % name)
if not os.path.isdir(git_dir):