diff options
author | Lars Wirzenius <liw@liw.fi> | 2017-07-29 18:51:19 +0300 |
---|---|---|
committer | Lars Wirzenius <liw@liw.fi> | 2017-07-29 18:51:19 +0300 |
commit | 6306ac5db1dff2327e6dafbbdaaa2cc51ce98bda (patch) | |
tree | 144def27588a93b49889d47127f2fde31f0d791c /yarns | |
parent | 386e2658e83dc4bc27fa921499b4445bb8ac3d60 (diff) | |
download | ick2-6306ac5db1dff2327e6dafbbdaaa2cc51ce98bda.tar.gz |
Add: scenario step configures multiple projects
Diffstat (limited to 'yarns')
-rw-r--r-- | yarns/900.yarn | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/yarns/900.yarn b/yarns/900.yarn index 4727dbd..8ee31f3 100644 --- a/yarns/900.yarn +++ b/yarns/900.yarn @@ -37,14 +37,19 @@ IMPLEMENTS GIVEN a project (\S+), using (\S+), publishing to (\S+) project = yarnutils.get_next_match() repo = yarnutils.get_next_match() - server = yarnutils.get_next_match() - config = { - 'projects': { - project: { - 'git': repo, - 'shell_steps': ['ikiwiki --build', 'rsync'], - }, - }, + + if os.path.exists('ick.ick'): + config = yaml.safe_load(open('ick.ick')) + else: + config = { + 'projects': {} + } + config['projects'][project] = { + 'git': repo, + 'shell_steps': [ + 'ikiwiki --build', + 'rsync', + ], } write('ick.ick', yaml.safe_dump(config)) |