Age | Commit message (Collapse) | Author | Files | Lines |
|
This closes #231.
|
|
save modification time with sub-second granularity
|
|
|
|
Some systems can get the file modification time with sub-second
granularity. However, Hakyll shaves off the sub-seconds, as defined in
the Binary instance of BinaryTime, which poses a problem because when a
file is checked to see if it was modified in `resourceModified`, it
still contains the sub-seconds. This results in a file (almost) always
being considered as having been modified.
Example:
1. First go around, modification time is 3:45.325. This time is saved
as 3:45.000 (i.e. sub-seconds are shaved off).
2. Second go around, modification time is again read as 3:45.325 and
compared against the stored time, 3:45.000. 3:45.325 is more recent
than 3:45.000, so the file is considered to have been modified.
This change prevents the shaving off of sub-seconds. This will naturally
work on systems that don't support sub-second granularity, as that
'field' will simply appear as all zeros.
Closes #250
|
|
OS won't change mid-execution, so lets avoid the unnecessary
check each time `unixFilter` is run.
|
|
|
|
|
|
|
|
|
|
|
|
This reverts commit e0f45b29b3f5e17c04ecd054b6c26c67d71e10e4.
Conflicts:
src/Hakyll/Core/Provider/Metadata.hs
|
|
This reverts commit e71bbd90a8fb4b5de7796498aed4b95bb7abaebb.
|
|
This reverts commit a6ae4eb99dd5f9957adc3b5fe4011e69b9681e4c.
|
|
This reverts commit 712ffa39b5857fdc5cdae1db38a177267a430b11.
Conflicts:
src/Hakyll/Core/Metadata.hs
src/Hakyll/Core/Rules/Default.hs
|
|
This reverts commit 46b6f78da8ed814bef6972f4712d8b13e76c1122.
Conflicts:
tests/data/posts/metadata
|
|
This reverts commit d406db44e39d310a72ca6bb014ed882f0e883995.
|
|
Fix unixFilter on Windows
|
|
|
|
|
|
On windows, the 'unixFilter' function used window's 'createProcess'
function to create the external process that will filter some String
input. The problem with this is that it is unable to execute batch
stubs (eg. anything created using 'gem install ...') even if its in
$PATH. Anyways a solution to this issue is to execute the batch file
explicitly using 'cmd /c batchfile' but there is no rational way to know
where said batchfile is on the system. My solution is to detect windows
using the System.Info module and then instead of using 'proc' to create
the function, use 'shell' instead which will be able to execute
everything 'proc' can + batch files.
Inspired by: http://www.blaenkdenum.com/posts/the-switch-to-hakyll/#scss
Signed-off-by: Collin J. Doering <rekahsoft@gmail.com>
|
|
|
|
The old test returns an exit code of 1 whenever the number of
errors is >= 0, which should always be the case. The fix replaces
this with a test whether the number of errors is strictly > 0.
|
|
|
|
Added the `pandocCompilerWithTransformM` function
|
|
|
|
|
|
Implemented per-directory metadata support
|
|
Didn't clean up unused code though
|
|
|
|
Closes #150
|
|
|
|
|
|
Web.Template.Context
|
|
|
|
|
|
This reverts commit ffbce966075d258b16b44e6856333ef41e4487f4.
|
|
|
|
Closes #191
|
|
|
|
I had to prepend some Rules to global Rules set. This might be possible
to replaced by a correct Store.set call.
I also had to prepend some Compile rules.
|
|
|
|
|
|
|
|
|
|
Pandoc 1.12 decouples citeproc-hs from itself, so there is no longer a
Text.Pandoc.Biblio module in Pandoc. Further, citeproc-hs depends on
pandoc-types 1.10 but Pandoc 1.12 depends on pandoc-types 1.12. To
alleviate these issues, pandoc-citeproc was created which includes a
copy of the citeproc-hs source made to be compatible, since the
developer of citeproc-hs is apparently MIA.
pandoc-citeproc is a separate module that handles the mixture of
citeproc-hs and Pandoc. It includes `processCites` in Text.CSL.Pandoc,
which is the new name of what used to be `processBiblio` from
Text.Pandoc.Biblio
Most of these changes are seamless, consisting of simple name changes in
both functions and modules. However, a more direct change in the
Hakyll API itself is that `readPandocBiblio`'s second parameter, the
CSL, is now mandatory, i.e. not of type Maybe. This is to reflect the
same change in the underlying processing function from Text.CSL.Pandoc,
`processCites`, where the Style argument is now mandatory, and the style
is derived from the CSL.
See the old function:
processBiblio :: Maybe Style -> [Reference] -> Pandoc -> Pandoc
Compared to the new one:
processCites :: Style -> [Reference] -> Pandoc -> Pandoc
Sources:
* http://hackage.haskell.org/packages/archive/pandoc/1.11.1/doc/html/Text-Pandoc-Biblio.html
* http://hackage.haskell.org/packages/archive/pandoc-citeproc/0.1/doc/html/Text-CSL-Pandoc.html
Similarly, there is no longer a `readerReferences` field in the reader
options structure.
|
|
toSiteRoot uses splitPath, joinPath, and takeDirectory from the
System.FilePath module. On Windows systems, the implementation of
joinPath will build up a path using the Windows path separator "\\".
We don't want this behavior since the paths we are working with
are always URLs, so we force POSIX behavior for System.FilePath.
|
|
Make it possible to specify the default port to listen on when the
preview server is run. This is useful if another service on the system
already runs on port 8000 (the default), since it's a hassle to keep
providing the port overriding option. For example: ./site preview vs.
./site preview -p 4000
|
|
* Details on how to disable the server in the command description.
|
|
1. Added an argument to watch, --no-server which will disable the embedded server.
1. Added a deprecation message to the preview mode
|
|
|