Otherwise, `RELATIVE_URLS` in the config file is ignored and
`RELATIVE_URLS` is set to `False` if `--relative-urls` is not
specified.
Fixes an issue introduced in #1592
Added tests to ensure that:
- THEME and deprecated *_DIR settings result in the expected configurations
- Post headers are formatted correctly in both Markdown and reStructuredText
- Files specified in IGNORE_FILES setting are properly ignored
- Generator.get_files()'s `paths` argument is backwards-compatible with strings
Since PDF Generation is no longer a core feature, these settings are irrelevant. If the `pdf` plugin from pelican-plugins is used, it disregards the `PDF_GENERATOR` setting anyways.
* Fix {filename} links on Windows.
Otherwise '{filename}/foo/bar.jpg' doesn't work
* Clean up relative Posix path handling in contents.
* Use Posix paths in readers
* Environment for Popen must be strs, not unicodes.
* Ignore Git CRLF warnings.
* Replace CRLFs with LFs in inputs on Windows.
* Fix importer tests
* Fix test_contents
* Fix one last backslash in paginated output
* Skip the remaining failing locale tests on Windows.
* Document the use of forward slashes on Windows.
* Add some Fabric and ghp-import notes
There was an issue with static path watchers, where they were watching wrong paths.
They need to be prefixed with the 'content' path. So, they were not working at all.
It was also possible to overwrite default watchers like 'content', 'settings' and
'theme' by mistake if any of them were present in `STATIC_PATHS`. This is fixed
by adding a prefix to static watchers.
And static watchers were "too static", meaning, they stayed the same even if
`STATIC_PATHS` was changed in the settings during autoreload. Now static watchers
reflect those changes (i.e. new paths are added to watch list, and removed ones
are no longer watched).
This is helpful for mobile testing of Pelican sites by allowing
broadcasting on the local network. Using port 80 requires
running as root on most machines.
- Remove gratuitous Unixisms so that fabfile will work on Windows
- Docstrings for tasks so `fab --list` is more useful.
- Add `gh_pages` task for publishing to GitHub Pages
using [ghp-import](https://github.com/davisp/ghp-import)
Until now, making static files end up in the same output directory as an
article that links to them has been difficult, especially when the article's
output path is generated based on metadata. This changeset introduces the
{attach} link syntax, which works like the {filename} syntax, but also
overrides the static file's output path with the directory of the
linking document.
It also clarifies and expands the documentation on linking to internal content.
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.