* inital "just barely works" Fuse.js support
* implement FuseJavascript; refactor index_for_lang
* support search config
* move fuse index building to it's own file
* update doc of Search.index_format
* update config docs
* update search documentation
* use &str where possible
* use libs::serde_json
remmeber to commit Cargo.lock
* move extension logic to IndexFormat
* move the entire filename logic inside IndexFormat
* move elasticlunr to it's own module
* only create elasticlunr.min.js if we're actually using elasticlunr
* move ELASTICLUNR_JS to elasticlunr.js
* hide the details of search's submodules
* optionally include path
* explain include_path better
* remove references to stork
* replace if with match
* support include_description
* specify "permalink"
* move body cleaning and truncation to a function
* update truncate_content_length docs to specify *code points*
* Remove ensure_directory_exists since it's identical to create_directory, and misleading
* Don't create directories unless needed; rely on create_dir_all instead of manually iterating over components
* Fix hard link panic and add better error info to std:fs errors
* cargo fmt
* Remove erroneously committed config change
* Remove console import; Use with context to provide additional error info
* improve error wording
Previously the heuristic check for links required spaces before the
attribute to ensure that attributes suffixed with `id` were not
identified. This has now been expanded to any white space character to
enable the `id` attribute to start on a new line.
* Add YAML to formats supported by load_data()
A fairly trivial addition; JSON and YAML are handled so similarly
that this was a matter of copying the JSON-relevant handlers and
editing the copies to handle YAML as well. The test file was
literally generated with 'json2yaml'.
The documentation has been updated to indicate that load_data() now
handles YAML code.
The CHANGELOG has been updated as well.
* After checking, I found that it's generally agreed the mime type is still application/x-yaml.
* Update comment, unify library importing.
I noticed one more place where the list of formats was supported,
and added YAML to that list.
I noticed that there's a singular place to load the `libs::` crate,
and unified by importing of serde_yaml in that place.
* Make sure that zola serve/build can start from anywhere inside dir tree
* make clippy and rustfmt a bit happier
* replace unecessary if-else with unwrap_or and display which path could not get canonicalized if it fails at startup
* canonicalize config_path to avoid crash when config.toml changes
* Add heuristic checking for HTML anchors
Previously only anchors specified or generated in markdown could be
linked to, without complaint from the link checker. We now use a
simple heuristic check for `name` or `id` attributes.
Duplicate code has been refactored and all XML anchor checks updated
to use regex rather than substring match.
* Fix regexp and refactor
* Split checking for theme template off into separate function
Allows to check for fallbacks elsewhere in the code, without attempting to actually render the template.
* Add template fallback checking to taxonomy pages.
* Add template fallback checking to paginated taxonomies
Requires passing additional arguments to Paginator::from_taxonomy, which may not be desirable.
* Update documentation to reflect taxonomy template fallbacks.
* Update generic taxonomy template names.
* Make check_template_fallbacks() return &str.
* Add tests for check_template_fallbacks
* Next version
* Added tests for shortcode insertion
* Added TOC tests
* Added test for #1475 and #1355
* Basic internal / external links tests
* Added integration test
* Added pseudocode and started on logos
* Logos parsing for shortcodes
* Fixed string literal parsing
Moved string literal parsing to a new lexer in order to have greater
control of control characters which are parsed. This fixes the bug that
was present in the `string_from_quoted` function and also moves the
`QuoteType` to be in the `ArgValueToken`.
* Moved string literal logic to seperate module
* Added square bracket notation for variables
* Error handling rewritten
Remove the Result from the `fetch_shortcodes` function. Added proper
messages within the internal parsing.
* Reorganized and documented the shortcode submodule
* Added all logic for ShortcodeContext spans
* Added working insertion code for MD files
* Made functions generic over Markdown or HTML
* Add check for embedding bodies
* Structure of main function clear
* Added test for `new_with_transforms` function
* It runs!
* Added the code for handling p-ed html shortcodes
* Removed placeholders in markdown function
* Adjusted integration tests
* fetch_shortcodes now also returns a string
* Start of HTML insertion
* Kinda working everything
* Loading of shortcodes and builtins
* Fix tests
* Some missed fixes
* Tweaks + fmt
* Remove string literal handling
* Fix benches
* Grab shortcode def only once per site
* Fix benches
* Rewrite of parser
* Fix tests
* Add test for #1655
* Re-enable integration test
* Add test for #1601
* Add test for #1600
* Add test for #1500
* Add test for #1320
* Fix test on windows?
Co-authored-by: Gijs Burghoorn <g.burghoorn@gmail.com>
This updates rendered markdown structures in order to keep track
of all internal links, not anymore limiting to only those targeting
an explicit anchor fragment.
The goal of this rework is to allow building other features, such
as backlinks, on top of the existing collection of internal links.
* fix can not build zola with search/indexing-zh feature
* fix can not build components/utils after enabled indexing-zh feature
error[E0252]: the name `Deserialize` is defined multiple times
--> components/utils/src/de.rs:2:5
|
1 | use serde::{Deserialize, Deserializer};
| ----------- previous import of the macro `Deserialize` here
2 | use serde_derive::Deserialize;
| ^^^^^^^^^^^^^^^^^^^^^^^^^ `Deserialize` reimported here
|
= note: `Deserialize` must be defined only once in the macro namespace of this module