Closed dgryski closed 2 years ago
I can maybe take a look at this over the weekend
Ok so I got this so far for rewriting the repos
structure for all ye whippersnappers out there
type T struct {
Repo string
Tags string
Subdirs []string
}
And can be generated via
print("var repos = []T{\n")
for repo in repos:
print(f'{{\n\tRepo:"{repo["repo"]}",')
if 'tags' in repo:
print(f'\tTags:"{repo["tags"]}",')
if 'subdirs' in repo:
print('\tSubdirs: []string{')
for subdir in repo['subdirs']:
print(f'\t\t"{subdir}",')
print("},")
print("},")
print("}")
This started out as a bash for loop, which then became a bash script, and then finally a python script. Move this fully to Go. While we're at it, move the repo config out of the main binary.