diff options
-rwxr-xr-x | lorry | 20 |
1 files changed, 4 insertions, 16 deletions
@@ -237,9 +237,6 @@ class Lorry(cliapp.Application): self.settings.boolean(['check-certificates'], 'validate SSL/TLS server certificates', default=True) - self.settings.string(['raw-file-repo'], - 'Repository to store raw file mirrors in', - default='raw-file-mirrors') def process_args(self, args): status = 0 @@ -354,11 +351,7 @@ class Lorry(cliapp.Application): vcstype = spec['type'] if vcstype not in table: raise cliapp.AppException('Unknown VCS type %s' % vcstype) - if vcstype == 'raw-file': - # raw files all get added to a single repository. - dirname = self.dirname(self.settings['raw-file-repo']) - else: - dirname = self.dirname(name) + dirname = self.dirname(name) if not os.path.exists(dirname): os.mkdir(dirname) @@ -410,15 +403,10 @@ class Lorry(cliapp.Application): if not self.settings['pull-only']: if len(self.settings['mirror-base-url-push']) > 0: - if vcstype == 'raw-file': - repo_name = self.settings['raw-file-repo'] - else: - repo_name = name - if 'refspecs' in spec: - self.push_to_mirror_server(repo_name, active_repo, spec['refspecs']) + self.push_to_mirror_server(name, active_repo, spec['refspecs']) else: - self.push_to_mirror_server(repo_name, active_repo) + self.push_to_mirror_server(name, active_repo) def migrate_oldstyle_repos(self, dirname): # Migrate old-style active repository @@ -840,7 +828,7 @@ class Lorry(cliapp.Application): self.ensure_gitdir(gitdir) # Ensure the repo is up-to-date - pullurl = "%s/%s.git" % (self.settings['mirror-base-url-push'], self.settings['raw-file-repo']) + pullurl = "%s/%s.git" % (self.settings['mirror-base-url-push'], project_name) try: self.run_program(['git', 'fetch', pullurl, raw_file_refspecs], cwd=gitdir) except: |