Mercurial > piecrust2
comparison piecrust/baking/records.py @ 85:3471ffa059b2
Add a `BakeScheduler` to handle build dependencies. Add unit-tests.
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Wed, 03 Sep 2014 17:27:50 -0700 |
parents | 2fec3ee1298f |
children | e88e330eb8dc |
comparison
equal
deleted
inserted
replaced
84:b3ce11b2cf36 | 85:3471ffa059b2 |
---|---|
109 prev.rel_path != factory.rel_path) and | 109 prev.rel_path != factory.rel_path) and |
110 len(prev.out_uris) > 0 and prev.out_uris[0] == uri): | 110 len(prev.out_uris) > 0 and prev.out_uris[0] == uri): |
111 return prev | 111 return prev |
112 return None | 112 return None |
113 | 113 |
114 def getPreviousEntry(self, page, taxonomy_name=None, taxonomy_term=None): | 114 def getPreviousEntry(self, source_name, rel_path, taxonomy_name=None, |
115 key = _get_transition_key(page.source.name, page.rel_path, | 115 taxonomy_term=None): |
116 key = _get_transition_key(source_name, rel_path, | |
116 taxonomy_name, taxonomy_term) | 117 taxonomy_name, taxonomy_term) |
117 pair = self.transitions.get(key) | 118 pair = self.transitions.get(key) |
118 if pair is not None: | 119 if pair is not None: |
119 return pair[0] | 120 return pair[0] |
120 return None | 121 return None |