aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBryan Brattlof <hello@bryanbrattlof.com>2021-03-01 12:36:29 -0500
committerBryan Brattlof <hello@bryanbrattlof.com>2021-03-01 13:18:29 -0500
commit41de270bc1f7b6fa369590a562358b0e2d0bb6f8 (patch)
tree749612ca53dac9f22022bbc43ba05ad98db99b7c
parent3d70d02d0aa2552fb5914837db71f635c765e539 (diff)
downloadpelican-htmlmin-41de270bc1f7b6fa369590a562358b0e2d0bb6f8.tar.gz
pelican-htmlmin-41de270bc1f7b6fa369590a562358b0e2d0bb6f8.tar.bz2
update readme
update installation instructions for Pelican v4.5 simplify (and fix) the wording
-rw-r--r--readme.rst34
1 files changed, 15 insertions, 19 deletions
diff --git a/readme.rst b/readme.rst
index a8ac7d9..1730add 100644
--- a/readme.rst
+++ b/readme.rst
@@ -1,9 +1,9 @@
pelican-htmlmin
###############
-A `Pelican <https://github.com/getpelican/pelican/>`_ plugin that uses
+A `Pelican <https://github.com/getpelican/pelican/>`_ plugin using
`htmlmin <https://github.com/mankyd/htmlmin>`_ to remove comments and extra
-whitespace from your website after the pages have been generated.
+whitespace from your website.
Turning this:
@@ -26,22 +26,19 @@ Into this:
Installing
##########
-:code:`pelican-htmlmin`, is available on pip:
+:code:`pelican-htmlmin`, is available on :code:`pip` and takes advantage of
+Pelican's namespace system to automatically register installed plugins.
+
+Just install with :code:`pip` and you're ready to go:
.. code-block::
$ pip install pelican-htmlmin
-After you've installed the package, update the :code:`PLUGINS` variable in your
-:code:`pelicanconf.py` to include the package in your next pelican build.
-
-.. code-block:: python
+For a more detailed plugin installation guide, please refer to the
+`Pelican Plugin Documentation`_.
- PLUGINS = [
- # ...
- 'pelican_htmlmin',
- # ...
- ]
+.. _`Pelican Plugin Documentation`: https://docs.getpelican.com/en/latest/plugins.html
Options
#######
@@ -53,21 +50,20 @@ HTMLMIN_ENABLED
===============
By Default, if Pelican is in :code:`DEBUG` mode, :code:`pelican-htmlmin` will
-not minify any files, helping with debugging. To override this, set
-:code:`HTMLMIN_ENABLED = True` to minify your HTML files regardless of the
+not minify any files, to help with debugging. To override this, set
+:code:`HTMLMIN_ENABLED = True` to minify files regardless of the
:code:`DEBUG` flag.
.. code-block:: python
- # minify generated files only if pelican is not in DEBUG mode
- HTMLMIN_ENABLED = not logger.getEffectiveLevel() == logging.DEBUG
+ HTMLMIN_ENABLED = logger.getEffectiveLevel() > logging.DEBUG
HTMLMIN_MATCH
=============
-:code:`pelican-htmlmin` looks for files ending with :code:`.html` or
-:code:`.htm` to minify. You can use the :code:`HTMLMIN_MATCH` to change the
-regular expression that matches the files you wish to minify.
+Out of the box, :code:`pelican-htmlmin` looks for files ending with
+:code:`.html` or :code:`.htm` to minify. You can use the :code:`HTMLMIN_MATCH`
+to change the regular expression that matches the files you wish to minify.
.. code-block:: python