Commit graph

8 commits

Author SHA1 Message Date
Elias Kirchgässner
56e011d70a Merge branch 'master' of github.com-priv:lioman/Flex 2022-09-02 09:33:51 +02:00
Georg Lutz
1e31ab9b50 Fix tipue search
The tipue plugin registers itself as pelican.plugins.tipue_search (namespace
plugin) in the latest version see here:
7fe8f3f05c

Keep old style tipue_search to be compatible with old versions.

To use the search one would need to add "search" to DIRECT_TEMPLATES in
pelicanconf.py so that search.html is copied to the output folder:

    DIRECT_TEMPLATES = ["index", "tags", "categories", "archives", "search"]
2021-12-28 22:11:17 +01:00
lioman
4b76663ae1 move search files to search page
- To speed up page load the js files should be loaded on bottom of page.
- search files are only needed if you search. Move them to search page
- instantiate tipue search only on search page
2021-03-12 09:29:01 +01:00
lioman
cd7d10f5c9 move search files to search page
- To speed up page load the js files should be loaded on bottom of page.
- search files are only needed if you search. Move them to search page
- instantiate tipue search only on search page
2021-03-11 18:32:54 +01:00
saagit
c205163fd7 Fix compatibility with Pelican 4.5.0 when PLUGINS is not set in pelicanconf.py
Pelican 4.5.0 changed the plugins mechanism and the default for
PLUGINS is now None.  The following type of construct is used in a
number of places in Flex:

    {% if 'tipue_search' in PLUGINS %}

If PLUGINS is not set in pelicanconf.py, the following exception will
be triggered under Pelican 4.5.0:

    TypeError: argument of type 'NoneType' is not iterable

The Pelican maintainers did not intend the examination of PLUGINS by
templates to be a stable API (per a discussion on IRC).  Per their
request, an enhancement request for a mechanism to do this has been
submitted here: https://github.com/getpelican/pelican/issues/2797

This commit changes the problematic constructs in Flex to be in the
style of:

    {% if PLUGINS and 'tipue_search' in PLUGINS %}

This allows Flex to work with Pelican 4.5.0 even if users do not
define PLUGINS.  Note that to use the new namespace plugins in Pelican
4.5.0, PLUGINS will have to be left at its default of None.

Resolves #245
2020-09-10 08:42:20 -07:00
Alexandre Vicenzi
533bc1760e Fix identation and missing trans 2020-04-20 23:36:36 +02:00
Sumner Evans
bc855d825b
Check PLUGINS variable for tipue_search instead of using USE_TIPUE_SEARCH 2020-04-20 14:28:38 -06:00
Jack McKew
fbe7d17fb0
Add tipue search integration (#193)
* Add tipue search integration
2020-02-07 18:06:17 +01:00