Mercurial > piecrust2
comparison piecrust/sources/prose.py @ 866:d9059257743c
refactor: Make the linker work again.
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Mon, 12 Jun 2017 22:10:50 -0700 |
parents | f070a4fc033c |
children | a4d7ff2cdc5c |
comparison
equal
deleted
inserted
replaced
865:1bb0d973dc69 | 866:d9059257743c |
---|---|
15 | 15 |
16 def _doCreateItemMetadata(self, path): | 16 def _doCreateItemMetadata(self, path): |
17 metadata = super()._doCreateItemMetadata(path) | 17 metadata = super()._doCreateItemMetadata(path) |
18 config = metadata.setdefault('config', {}) | 18 config = metadata.setdefault('config', {}) |
19 config.update(self._makeConfig(path)) | 19 config.update(self._makeConfig(path)) |
20 return config | 20 return metadata |
21 | 21 |
22 def _makeConfig(self, path): | 22 def _makeConfig(self, path): |
23 c = copy.deepcopy(self.config_recipe) | 23 c = copy.deepcopy(self.config_recipe) |
24 if c.get('title') == '%first_line%': | 24 if c.get('title') == '%first_line%': |
25 c['title'] = get_first_line(path) | 25 c['title'] = get_first_line(path) |