Commit graph

2,331 commits

Author SHA1 Message Date
Justin Mayer
d5d821fd87 Merge pull request #1457 from svenkreiss/master
Add <ul> to authors.html template so HTML is valid
2014-11-02 14:55:04 -08:00
Justin Mayer
618d94c897 Merge pull request #1518 from iKevinY/merge-analytics
Merge piwik.html into analytics.html
2014-11-02 14:52:40 -08:00
Kevin Yap
da41f7681b Merge piwik.html into analytics.html
Addresses #1512.
2014-11-02 14:43:32 -08:00
Tom Most
e65d33b89c Warn that signal receivers are weakly-referenced
For the signal get_generators in particular, it may seem natural to use
a lambda or inner function as the signal receiver, but this does not
work as the receiver is collected before it can be called.
2014-11-02 14:39:08 -08:00
Justin Mayer
afe009e6c9 Merge pull request #1361 from ingwinlu/rewritten_summary_2
Re-work summary attribute to be memoizable
2014-11-02 14:32:41 -08:00
Justin Mayer
7d3c765927 Merge pull request #1358 from ingwinlu/md_exten_add
Improve docs regarding Python-Markdown extensions
2014-11-02 14:29:54 -08:00
Justin Mayer
45417832e1 Document Markdown inclusion in Quickstart install 2014-11-02 13:49:31 -08:00
winlu
636f83ab67 add paragraph mentioning markdown extensions to docs 2014-11-02 22:40:44 +01:00
Justin Mayer
de8b437549 Merge pull request #1466 from cgar/spelling
Minor spelling fixes
2014-11-02 12:20:30 -08:00
Justin Mayer
b4ae60b3d0 Merge pull request #1501 from foresto/subdir-excludes
Make PAGE_EXCLUDES and ARTICLE_EXCLUDES work with subdirs. Fixes #1500.
2014-11-02 12:09:24 -08:00
winlu
72f3b4a116 rework summary attribute
*   write summary property in modern style
*   introduce get_summary which is memoizable, based on localsiteurl
*   introduce get_siteurl
2014-11-02 20:02:58 +01:00
Forest
0fe290c321 Make PAGE_EXCLUDES work with subdirs. Fixes #1500.
The old code was naively comparing the strings in PAGE_EXCLUDES to the
subdirectory names produced by os.walk(). (Same with ARTICLE_EXCLUDES.)
This had two surprising effects:

Setting PAGE_EXCLUDES=['foo'] would exclude all directories named foo,
regardless of whether they were in the top-level content directory or
nested deep within a directory whose contents should not be excluded.

Setting PAGE_EXCLUDES=['subdir/foo'] would never exclude any directories.

In other words, there is no way to exclude a subdirectory without risking
the accidental exclusion of other directories with the same name elsewhere
in the file system.

This change fixes the problem, so 'subdir/foo' and 'foo' will be distinct
and both work as expected. If anyone out there is depending on the old
behavior, they will have to update their settings. I don't expect it to
affect most users yet, since Pelican doesn't yet make nested directory
structures very useful. When it does, this fix will become important to
more people.
2014-11-01 17:38:20 -07:00
Justin Mayer
a81fcd3fef Merge pull request #1509 from foresto/static-files-anywhere
Make StaticGenerator skip content sources. Refs #1019.
2014-11-01 14:34:33 -07:00
Forest
48f4f0850d Make StaticGenerator skip content sources. Refs #1019.
This change partially addresses issue #1019, by teaching Pelican to distinguish
between static files and content source files. A user can now safely add the
same directory to both STATIC_PATHS and PAGE_PATHS (or ARTICLE_PATHS). Pelican
will then process the content source files in that directory normally, and
treat the remaining files as static, without copying the raw content source
files to the output directory. (The OUTPUT_SOURCES setting still works.)

In other words, images and markdown/reST files can now safely live together.

To keep those files together in the generated site, STATIC_SAVE_AS and
PAGE_SAVE_AS (or ARTICLE_SAVE_AS) should point to the same output directory.

There are two new configuration settings:

STATIC_EXCLUDES=[]  # This works just like PAGE_EXCLUDES and ARTICLE_EXCLUDES.
STATIC_EXCLUDE_SOURCES=True  # Set this to False to get the old behavior.

Two small but noteworthy internal changes:

StaticGenerator now runs after all the other generators. This allows it to see
which files are meant to be processed by other generators, and avoid them.

Generators now include files that they fail to process (e.g. those with missing
mandatory metadata) along with all the other paths in context['filenames'].
This allows such files to be excluded from StaticGenerator's file list, so they
won't end up accidentally published. Since these files have no Content object,
their value in context['filenames'] is None. The code that uses that dict has
been updated accordingly.
2014-10-31 16:46:01 -07:00
Justin Mayer
f9bd4acb10 Merge pull request #1511 from olivierverdier/makefile_tab
Fix missing tab in Makefile template
2014-10-22 16:00:39 -07:00
Olivier Verdier
5b389d6f36 fix missing tab in Makefile template 2014-10-20 15:22:11 +02:00
Justin Mayer
17c551c793 Merge pull request #1484 from ingwinlu/complete_rss_feed_removal
add missing author feeds to pelicanconf template
2014-10-10 11:15:33 -07:00
Kyle Fuller
7feb638b5c Merge pull request #1487 from foresto/spelling
Spelling correction in docs: usefull -> useful.
2014-10-04 19:27:38 +01:00
Forest
96eaf9cea0 Spelling correction in docs: usefull -> useful. 2014-10-01 02:05:49 -07:00
tylerhartley
693ad3296c EXTRA_PATH_METADATA path separator is OS-specific
Updating docs for EXTRA_PATH_METADATA to clarify that OS-specific path
separators must be used as keys, unlike some other Pelican variables.
Refs # 1133.
2014-09-30 10:40:26 -07:00
winlu
9b4b123a0e add missing author feeds to pelicanconf template 2014-09-29 23:38:39 +02:00
Justin Mayer
c7b52bc730 Merge pull request #1473 from ingwinlu/patch-1
Update faq.rst to include missing Author Feeds
2014-09-22 08:08:26 -07:00
winlu
e4a2bb5b52 Update faq.rst
since author feeds are enabled per default http://docs.getpelican.com/en/latest/settings.html#id9 as well, these need to be added here as well.
2014-09-22 16:36:34 +02:00
Justin Mayer
08d5221114 Merge pull request #1374 from singingwolfboy/readme-badges
README: Added Coveralls badge, refactor Travis badge
2014-09-19 07:59:34 -07:00
David Baumgold
683d10a480 README: Added Coveralls badge, refactor Travis badge 2014-09-19 10:47:31 -04:00
Justin Mayer
9bf22f20bf Merge pull request #1470 from avaris/fix_1348
Fix for broken test in #1348
2014-09-18 19:07:00 -07:00
Deniz Turgut
dec6023fe6 Fix for broken test in #1348 2014-09-18 20:09:12 -04:00
Justin Mayer
426c7428d6 Merge pull request #1426 from barrysteyn/DOCUTILS_SETTINGS
Documents DOCUTILS_SETTINGS and initializes it. Fixes #1425
2014-09-18 16:17:46 -07:00
Justin Mayer
fbc65e0d7b Merge pull request #1366 from Scheirle/paginated_relative_urls_fix2
Fixes wrongly generated relative urls for pagination.
2014-09-18 16:15:21 -07:00
Justin Mayer
1d9981b4f9 Merge pull request #1348 from vjousse/davidmarble-page-order-by
Support ordering pages and articles when iterating in templates.
2014-09-18 16:12:51 -07:00
Carlos E. Garcia
f5775bcba0 minor spelling fixes 2014-09-15 20:29:00 -04:00
Sven Kreiss
8cf89bd623 add <ul> to make valid html 2014-09-05 22:34:29 -04:00
Justin Mayer
cb11bea1f2 Merge pull request #1408 from arty-name/feed-written
Add feed_written signal
2014-08-28 11:19:58 -07:00
Justin Mayer
1fae9534d5 Merge pull request #1446 from avaris/enhanced_strftime
Fixes #1395: extends pelican.utils.strftime with `-` prefix to strip leading zeros
2014-08-28 11:17:28 -07:00
Artemy Tregubenko
0093984861 Add feed_written signal 2014-08-28 20:09:42 +02:00
Justin Mayer
2b130fb4dd Merge pull request #1438 from mlissner/patch-2
Add reference to SLUGIFY_SOURCE
2014-08-23 13:05:20 -07:00
Justin Mayer
b357592248 Merge pull request #1445 from avaris/fix_1420
Fixes #1420: Handle multiple definitions of standard metadata for Markdown
2014-08-22 15:15:38 -07:00
Deniz Turgut
a2bb80b8bd Fixes #1420: Handle multiple definitions of standard metadata for Markdown 2014-08-22 17:53:36 -04:00
Justin Mayer
b8c9d61f20 Merge pull request #1411 from barrysteyn/typogrify-ignore-list
Allow Typogrify to ignore user specified tags. Refs #1407
2014-08-17 07:18:19 -06:00
Mike Lissner
04978e9b75 Adds reference to SLUGIFY_SOURCE
When working on my site, I wanted SLUGIFY_SOURCE, but I came across PATH_METADATA first and enabled that for a while. Better to include the cross-reference where people can find it.
2014-08-16 21:07:30 -07:00
Justin Mayer
2ecd85d7b3 Merge pull request #1412 from avaris/refactor_logging
Refactor logging handling
2014-08-13 14:17:09 -07:00
Kyle Fuller
5563b9baf4 Merge pull request #1418 from willingc/fix-doc-typo
Corrected typo to improve readability
2014-08-03 00:53:07 +01:00
Justin Mayer
4261b9f5d0 Merge pull request #1371 from omasanori/tz
Add timezone to datetime objects. Refs #962.
2014-08-02 07:38:08 -07:00
Barry Steyn
b3b65d77e0 Documents DOCUTILS_SETTINGS and initializes it. Fixes #1425 2014-07-31 18:04:35 -07:00
Barry Steyn
a0ecab901f Allows Typogrify to ignore user specified tags. Refs #1407
Typogrify interferes with certain sections of the output that it should not touch (see #1407 for more details).
This feature adds a setting called TYPOGRIFY_IGNORE_LIST which is a list of tag for Typogrify to ignore.

The following was updated:

 1. readers.py - if TYPOGRIFY_IGNORE_TAGS is present, then use it
 2. settings.ps - default TYPOGRIFY_IGNORE_TAGS to []
 3. contents/article_with_code_block.rst - an article with a code block for typogrify to ignore
 4. updated tests
 5. updated documentation
2014-07-28 15:17:12 -07:00
Carol Willing
c995fa87a7 Corrected typo to improve readability 2014-07-27 07:33:05 -07:00
Ondrej Grover
3b54f3e418 Merge pull request #1415 from RR2DO2/patch-1
Debug print removal

the print() was a leftover from caching development.
2014-07-26 09:15:14 +02:00
RR2DO2
df0731f2e8 Debug print removal
The print either is a debug print that needs removing, or needs an additional description. The first is more likely.
2014-07-25 19:24:40 +01:00
Deniz Turgut
ed3209888a Refactor logging handling
Old system was using manual string formatting for log messages.
This caused issues with common operations like exception logging
because often they need to be handled differently for Py2/Py3
compatibility. In order to unify the effort:

 - All logging is changed to `logging.level(msg, arg1, arg2)` style.
 - A `SafeLogger` is implemented to auto-decode exceptions properly
in the args (ref #1403).
 - Custom formatters were overriding useful logging functionality
like traceback outputing (ref #1402). They are refactored to be
more transparent. Traceback information is provided in `--debug`
mode for `read_file` errors in generators.
 - Formatters will now auto-format multiline log messages in order
to make them look related. Similarly, traceback will be formatted in
the same fashion.
 - `pelican.log.LimitFilter` was (ab)using logging message which
would result in awkward syntax for argumented logging style. This
functionality is moved to `extra` keyword argument.
 - Levels for errors that would result skipping a file (`read_file`)
changed from `warning` to `error` in order to make them stand out
among other logs.
 - Small consistency changes to log messages (i.e. changing all
to start with an uppercase letter) and quality-of-life improvements
(some log messages were dumping raw object information).
2014-07-22 12:39:39 -04:00
Justin Mayer
f1a9d50a06 Merge pull request #1323 from DandyDev/access-reader-names
Reader name now accessible for articles and pages
2014-07-18 09:12:00 -07:00