You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

40 lines
1.0 KiB

Allow buildbot to run jobs dynamically defined a a project repo
Requires docker
# TODO: change "ghcontext" in master.cfg to interpolate the job name
# TODO: write upload script
# TODO: write hook (perhaps the default hook is ok), authentication for hook
# TODO: write hook job, maybe also a dockerfile?
# TODO: what to do about non-docker jobs
from os import walk
from os.path import exists, isfile, join, listdir
def list_jobs(directory=".buildbot"):
list jobs found in a directory
results = []
for _ in next(walk(directory))[1]:
if exists(join(directory, _, "Dockerfile")) \
and (exists(join(directory, _, ""))
or exists(join(directory, _, ""))
return results
def find_artifacts(directory="out"):
find artifacts (any file) in a directory
for _ in listdir(directory):
if not isfile(join(directory, _)):
return join(directory, _)