diff options
author | Kyle Mckay <kyle.mckay@codethink.co.uk> | 2021-10-27 09:20:08 +0100 |
---|---|---|
committer | Kyle Mckay <kyle.mckay@codethink.co.uk> | 2021-11-04 09:26:02 +0000 |
commit | f7381735d07ea414f875a32da4854b99dac47ed7 (patch) | |
tree | 4f44bc97fac23a84b60126e5a67a025e30a8b1f7 /lorry | |
parent | ae7a1aa61e899be6bb90510897046d27c8d6e126 (diff) | |
download | lorry-f7381735d07ea414f875a32da4854b99dac47ed7.tar.gz |
Remove use of raw-file monorepo
Diffstat (limited to 'lorry')
-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: |