Mercurial > piecrust2
annotate piecrust/__init__.py @ 334:b034f6f15e22
bake: Several bug taxonomy-related fixes for incorrect incremental bakes.
* Improve how the baker processes taxonomy terms and figures out what needs
to be re-baked or not.
* Create bake entries for clean taxnomy terms so they're not deleted by an
incremental bake.
* Add more information to bake records.
* Slugify taxonomy terms is now done by the route in one place.
* Fix a bug where the cache key for invalidating rendered segments was not
computed the same way as when the caching was done.
* Fix how term combinations are passed around, rendered, printed, parsed, etc.
(TODO: more word needed in the routing functions)
* Expose to the template whether a taxonomy term is a combination or not.
* Display term combinations better in the built-in theme.
* Rename `route.taxonomy` to `route.taxonomy_name` to prevent confusion.
* Add options to show bake records for previous bakes.
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Fri, 03 Apr 2015 10:59:50 -0700 |
parents | 869a206facd5 |
children | 0e9a94b7fdfa |
rev | line source |
---|---|
3
f485ba500df3
Gigantic change to basically make PieCrust 2 vaguely functional.
Ludovic Chabant <ludovic@chabant.com>
parents:
0
diff
changeset
|
1 |
f485ba500df3
Gigantic change to basically make PieCrust 2 vaguely functional.
Ludovic Chabant <ludovic@chabant.com>
parents:
0
diff
changeset
|
2 CACHE_DIR = '_cache' |
36
485682a6de50
New site layout support.
Ludovic Chabant <ludovic@chabant.com>
parents:
3
diff
changeset
|
3 ASSETS_DIR = 'assets' |
485682a6de50
New site layout support.
Ludovic Chabant <ludovic@chabant.com>
parents:
3
diff
changeset
|
4 TEMPLATES_DIR = 'templates' |
485682a6de50
New site layout support.
Ludovic Chabant <ludovic@chabant.com>
parents:
3
diff
changeset
|
5 THEME_DIR = 'theme' |
3
f485ba500df3
Gigantic change to basically make PieCrust 2 vaguely functional.
Ludovic Chabant <ludovic@chabant.com>
parents:
0
diff
changeset
|
6 |
36
485682a6de50
New site layout support.
Ludovic Chabant <ludovic@chabant.com>
parents:
3
diff
changeset
|
7 CONFIG_PATH = 'config.yml' |
485682a6de50
New site layout support.
Ludovic Chabant <ludovic@chabant.com>
parents:
3
diff
changeset
|
8 THEME_CONFIG_PATH = 'theme_config.yml' |
273
d70a4adb61dd
themes: Add the `chef themes` command
Ludovic Chabant <ludovic@chabant.com>
parents:
100
diff
changeset
|
9 THEME_INFO_PATH = 'theme_info.yml' |
3
f485ba500df3
Gigantic change to basically make PieCrust 2 vaguely functional.
Ludovic Chabant <ludovic@chabant.com>
parents:
0
diff
changeset
|
10 |
f485ba500df3
Gigantic change to basically make PieCrust 2 vaguely functional.
Ludovic Chabant <ludovic@chabant.com>
parents:
0
diff
changeset
|
11 DEFAULT_FORMAT = 'markdown' |
f485ba500df3
Gigantic change to basically make PieCrust 2 vaguely functional.
Ludovic Chabant <ludovic@chabant.com>
parents:
0
diff
changeset
|
12 DEFAULT_TEMPLATE_ENGINE = 'jinja2' |
f485ba500df3
Gigantic change to basically make PieCrust 2 vaguely functional.
Ludovic Chabant <ludovic@chabant.com>
parents:
0
diff
changeset
|
13 DEFAULT_POSTS_FS = 'flat' |
f485ba500df3
Gigantic change to basically make PieCrust 2 vaguely functional.
Ludovic Chabant <ludovic@chabant.com>
parents:
0
diff
changeset
|
14 DEFAULT_DATE_FORMAT = '%b %d, %Y' |
f485ba500df3
Gigantic change to basically make PieCrust 2 vaguely functional.
Ludovic Chabant <ludovic@chabant.com>
parents:
0
diff
changeset
|
15 DEFAULT_THEME_SOURCE = 'http://bitbucket.org/ludovicchabant/' |
f485ba500df3
Gigantic change to basically make PieCrust 2 vaguely functional.
Ludovic Chabant <ludovic@chabant.com>
parents:
0
diff
changeset
|
16 |
f485ba500df3
Gigantic change to basically make PieCrust 2 vaguely functional.
Ludovic Chabant <ludovic@chabant.com>
parents:
0
diff
changeset
|
17 PIECRUST_URL = 'http://bolt80.com/piecrust/' |
f485ba500df3
Gigantic change to basically make PieCrust 2 vaguely functional.
Ludovic Chabant <ludovic@chabant.com>
parents:
0
diff
changeset
|
18 |
69
cb1ed436642c
Always use version generated by `setup.py`. Better version generation.
Ludovic Chabant <ludovic@chabant.com>
parents:
36
diff
changeset
|
19 try: |
cb1ed436642c
Always use version generated by `setup.py`. Better version generation.
Ludovic Chabant <ludovic@chabant.com>
parents:
36
diff
changeset
|
20 from piecrust.__version__ import APP_VERSION |
cb1ed436642c
Always use version generated by `setup.py`. Better version generation.
Ludovic Chabant <ludovic@chabant.com>
parents:
36
diff
changeset
|
21 except ImportError: |
cb1ed436642c
Always use version generated by `setup.py`. Better version generation.
Ludovic Chabant <ludovic@chabant.com>
parents:
36
diff
changeset
|
22 APP_VERSION = 'unknown' |
cb1ed436642c
Always use version generated by `setup.py`. Better version generation.
Ludovic Chabant <ludovic@chabant.com>
parents:
36
diff
changeset
|
23 |
100
69d5eecfa449
Better `prepare` command, with templates and help topics.
Ludovic Chabant <ludovic@chabant.com>
parents:
69
diff
changeset
|
24 import os.path |
69d5eecfa449
Better `prepare` command, with templates and help topics.
Ludovic Chabant <ludovic@chabant.com>
parents:
69
diff
changeset
|
25 RESOURCES_DIR = os.path.join(os.path.dirname(__file__), 'resources') |
69d5eecfa449
Better `prepare` command, with templates and help topics.
Ludovic Chabant <ludovic@chabant.com>
parents:
69
diff
changeset
|
26 |