summaryrefslogtreecommitdiff
path: root/morphlib/app.py
diff options
context:
space:
mode:
authorRichard Maw <richard.maw@gmail.com>2014-09-03 21:03:56 +0000
committerRichard Maw <richard.maw@gmail.com>2014-09-19 12:43:26 +0000
commit30bd3185050bc7997a032ca32f0a5ac9b5e76ed9 (patch)
tree8f2c011823945af4d79e9e5bc850477a61b58e5f /morphlib/app.py
parente3400ec5a25b5163293adcb0d007d0a8cae53a4c (diff)
downloadmorph-30bd3185050bc7997a032ca32f0a5ac9b5e76ed9.tar.gz
Create multiple sources per stratum morphology
Building per-artifact results in undesirable behaviour, as multiple artifacts are produced for every chunk build. It therefore makes more sense to build per-source. This implies that actually, the model of one source per morphology is wrong and we should move the dependencies into the source. Unlike chunks however, where every chunk artifact has the same dependencies, stratum artifacts can have different dependencies. So before we can move the dependencies into the Source, we need to have as many Sources as Stratum Artifacts.
Diffstat (limited to 'morphlib/app.py')
-rw-r--r--morphlib/app.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/morphlib/app.py b/morphlib/app.py
index 88eb58a4..fae4c84b 100644
--- a/morphlib/app.py
+++ b/morphlib/app.py
@@ -290,9 +290,11 @@ class Morph(cliapp.Application):
pool = morphlib.sourcepool.SourcePool()
def add_to_pool(reponame, ref, filename, absref, tree, morphology):
- source = morphlib.source.Source(reponame, ref, absref, tree,
- morphology, filename)
- pool.add(source)
+ sources = morphlib.source.make_sources(reponame, ref,
+ filename, absref,
+ tree, morphology)
+ for source in sources:
+ pool.add(source)
self.traverse_morphs(repo, ref, [filename], lrc, rrc,
update=not self.settings['no-git-update'],