- Homepage
- https://github.com/adamConnerSax/knit-haskell#readme
- Author
- Adam Conner-Sax
- Uploaded
- by adamCS at 2020-07-02T18:02:33Z
- Maintainer
- adam_conner_sax@yahoo.com
v0.8.0.0
BREAKING: moved config arguments to
knit-html
andknit-htmls
into a data structureKnitConfig
. This breaks all existing uses of those functions but is designed to future-proof against additions to the knit configuration. A breaking change was more-or-less necessitated by the addition of a cache directory parameter for the persistent caching effect. See below.New persistent caching effect. Anything which has an instance of
Serialize
(from the cereal package) may be cached, in memory and backed by a disk-based cache (cache effect will attempt to create directories as required). When knit-html(s) is next run, the cached version can be used in place of running an expensive computation. This comes with some built-in dependency management, via modification times of the files in cache or user-provided time for dependencies on non-cached assets. For more information, see the Readme. For an example, see examples/CacheExample.hs.Added Async into knit-haskell effects. For an example, see examples/AsyncExample.hs.
Logging changes:
- Added a
Debug Int
level belowDiagnostic
with an integer argument to allow various and unlimited debug levels - Changed the previous
[LogSeverity]
argument given to run functions to(LogSeverity -> Bool)
to accomdate the non-Boundedness of the newDebug Int
levels. - Made logging thread-aware by making prefixes thread-local
and doing IO output of logs via theSay
library - Added type synonyms
PrefixedLogEffects
andPrefixedLogEffectsLE
for type-level-lists of logging effects
- Added functions to handle the failure branch of
Maybe
andEither Text
as errors. - Added
knitMapError
to absorb other types of errors. - Updated some dependency bounds (NB: tests now depend on random-fu >= 2.7.3 since previous versions had bad log-domain bounds)
- Updated for Pandoc >= 2.8. String to Text and template handling changes. All conditional (via CPP) so should work with < 2.8 as well.
v0.7.0.0
- Updated vega versions in pandoc templates
- removed (internal) datadir function because we now use the function
from the autogenerated
Paths_knit-haskell
module. Which has its own complications but the other version didn't work at all. - Added more constraints to Knit.Report.KnitEffects to simplify things.
If you use them to constrain a function to procuce something that can be knitted you will have all the knit effects available. - Where possible changed package bounds to >= A.B.C && < D.E. Most were already and some were easy to change. There are some lower bounds that are more specific and I won't generalize those unless I test them.
- Changed bounds for hvega, polysemy and polysemy-zoo. Downstream changes to account for this.
- SimpleExample now uses default template so that it also serves as a test that default templates are found.
v 0.6.0.1 - (Released 2019-06-21)
- Moved the Pandoc default templates so they will be installed where Pandoc expects them. This is hard to test!
v 0.6.0.0 - (Released: 2019-06-19)
- updated to use polysemy-zoo version of constraint absorbers in PandocMonad.
- Hackage download should now include templates and associated css
- Added mkPandocWriterConfig and addCss function in Knit.Report.Output to handle loading things in the included directory, which may be installed in a platform independent way.
- Added two more html templates, pandoc-bootstrap-KH.html and pandoc-adaptive-bootstrap-KH.html with pandoc-bootstrap.css and used them in some of the examples.
- Added the default html templates into the pandoc-templates directory where Pandoc will expect them if the given template fails.
- Reorganized data directory with "pandoc-data" "knit-haskell-templates" and "knit-haskell-css"
- Added output helpers for Pandoc results which are lazy text (html). These create the required parent directories if necessary. See examples for details.
- Removed
Knit.Effect.RandomFu
and modified the example which uses it to use the "polysemy-RandomFu" package instead.
v 0.5.0.0
- Added plots example back since there is a version of plots on hackage with a relaxed upper bound on containers.
- Changed the Doc effect so that instead of Text name, it carries a polymorphic info type.
This is then specified in the Pandoc case to be a Text name and set of template var overrides. This creates several other changes and will break any multi-doc examples since now "newPandoc" takes a first argument of the typePandocInfo
(which is just a product of aText
and aMap String String
). - raised lower bound and relaxed upper bound on polysemy
v 0.4.0.0
- Added
absorbPandocMonad :: PandocEffects r => (forall m. PandocMonad m => m a) -> Sem r a
toKnit.Effect.PandocMonad
- Removed (orphan) instances:
PandocMonad (Sem r)
andMonadError PandocError (Sem r)
in favor of usingabsorbPandocMonad
when required. - Deprecated name "Random" in favor of "RandomFu" for clarity and eventual consistency with Polysemy
- Added
absorbMonadRandom :: Member RandomFu r => (forall m. MonadRandom m => m a) -> Sem r a
to allow some interoperation with actions constrained byMonadRandom
- Removed orphan
Random.MonadRandom
instance fromKnit.Effect.RandomFu
because orphan instances are bad. - Changed return type of
Knit.Report.knitError
toSem r a
(fromSem r ()
) - Bumped lower bound on polysemy-plugin (because of a buggy version)
- Bumped lower bound on polysemy
- Removed plots example in "SimpleExample" and added a diagrams one.
Will add plots back once a version issue with containers is resolved.
v 0.3.0.1
- Examples were "executables" and are now "tests" so that depending on knit-haskell does not pull in the dependencies of the examples.
v 0.3.0.0
- Added exports of "Colonnade" and "Text.Blaze.Colonnade" to "Knit.Report.Input.Table.Colonnade"
- Added "knitError" function to Knit.Report to allow user throwing of errors.
These will become PandocSomeError and handled as a PandocError. - Lowered bound on containers (to 0.5.0) to accomodate use of Plots.
- Added Knit.Report.Input.Visualization.Diagrams.
Adds Diagrams from diagrams-lib via SVG backend. - Added some more re-exports (Colonnade, Diagrams.Prelude) from Knit.Report to simplify imports on use.
- Added an optional figure caption argument to Hvega and Diagrams inputs. (this is a breaking change since it requires another argument).
- Added a state effect wrapper to facilitate getting unused ids for figures, etc.
- Changed id argument for Hvega and Diagrams
visualizations to "Maybe Text" from Text.
Will use built-in facilities for unique ids when set to Nothing. - Visualization "addXXX" functions now return the figure id (as "Sem r Text") so it can be referred to elsewhere.
- Added KnitOne and KnitMany constraint-type-aliases to Knit.Report to simplify constraining doc producing functions.
- Updated examples. Added a diagrams example to SimpleExample and fixed id and caption arguments throughout.
- Bumped upper bounds (network)
v 0.2.0.0
- Documentation Fixes
- Added export of newPandoc and NamedDoc to Knit.Report to facilitate multi-doc use.
- Removed redundant imports from Knit.Report.Input.Table.Colonnade
- Added a multi-doc example
- (internal) Removed odd, and no longer necessary, "LastMember" constraint from knit functions.
- Updated effects for polysemy 1.2
v 0.1.0.0
- Initial version