Skip to content
Snippets Groups Projects
Commit 4db837e3 authored by Konstantin Baierer's avatar Konstantin Baierer
Browse files

record whether repo is official or not

parent de8447fb
No related branches found
No related tags found
No related merge requests found
......@@ -21,7 +21,11 @@ class CliCtx():
def __init__(self, config_file):
with open(config_file, 'r') as f_config_file:
self.config = safe_load(f_config_file.read())
self.repos = [Repo(self.config, url) for url in self.config['repolist']]
self.repos = []
for repo_desc in self.config['repolist']:
url = repo_desc['url']
official = repo_desc.get('official', False)
self.repos.append(Repo(self.config, url, official))
pass_ctx = click.make_pass_decorator(CliCtx)
@click.group()
......
......@@ -2,19 +2,26 @@
repodir: /data/ocrd_all
# repos to clone and process
repolist:
- https://github.com/ASVLeipzig/cor-asv-ann
- https://github.com/ASVLeipzig/cor-asv-fst
- https://github.com/OCR-D/ocrd_calamari
- https://github.com/OCR-D/ocrd_im6convert
- https://github.com/OCR-D/ocrd_keraslm
- https://github.com/OCR-D/ocrd_kraken
- https://github.com/OCR-D/ocrd_ocropy
- https://github.com/OCR-D/ocrd_olena
- https://github.com/OCR-D/ocrd_segment
- https://github.com/OCR-D/ocrd_tesserocr
- https://github.com/cisocrgroup/ocrd_cis
- https://github.com/mjenckel/LAYoutERkennung
- https://github.com/ocr-d-modul-2-segmentierung/segmentation-runner
- https://github.com/qurator-spk/dinglehopper
- https://github.com/qurator-spk/pixelwise_segmentation_SBB
- https://github.com/seuretm/ocrd_typegroups_classifier
- url: https://github.com/ASVLeipzig/cor-asv-ann
official: true
- url: https://github.com/ASVLeipzig/cor-asv-fst
official: true
- url: https://github.com/OCR-D/ocrd_calamari
- url: https://github.com/OCR-D/ocrd_im6convert
- url: https://github.com/OCR-D/ocrd_keraslm
- url: https://github.com/OCR-D/ocrd_kraken
- url: https://github.com/OCR-D/ocrd_ocropy
- url: https://github.com/OCR-D/ocrd_olena
- url: https://github.com/OCR-D/ocrd_segment
- url: https://github.com/OCR-D/ocrd_tesserocr
official: true
- url: https://github.com/cisocrgroup/ocrd_cis
official: true
- url: https://github.com/mjenckel/LAYoutERkennung
official: true
- url: https://github.com/ocr-d-modul-2-segmentierung/segmentation-runner
official: true
- url: https://github.com/qurator-spk/dinglehopper
- url: https://github.com/qurator-spk/pixelwise_segmentation_SBB
- url: https://github.com/seuretm/ocrd_typegroups_classifier
official: true
......@@ -10,10 +10,11 @@ LOG = getLogger('kwalitee.repo')
class Repo():
def __init__(self, config, url):
def __init__(self, config, url, official=False):
self.url = url
self.config = config
self.name = Path(url).name
self.official = official
self.path = Path(self.config['repodir'], self.name)
def __str__(self):
......@@ -73,6 +74,7 @@ class Repo():
def to_json(self):
desc = {}
desc['url'] = self.url
desc['official'] = self.official
desc['org_plus_name'] = '/'.join(self.url.split('/')[-2:])
desc['name'] = self.name
desc['files'] = self.get_file_contents()
......
This diff is collapsed.
click >=7
ocrd >= 1.0.0
ocrd >= 2.0.0a1
pyyaml
requests
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment