This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description

This is a generic HTML minifier NOT using regular expressions. This minifier is fully HTML5 compatible.

The name is coming from the Harry Potter books and is an incantation that forces objects to shrink

This project was started because of the lack of a maintained HTML minifier not using complex regexp. This project uses beautifulsoup to navigate the HTML flow.

Install

$ pip install python-diminuendo

Usage

TODO

HTML minification

>>> from diminuendo import htmlmin
>>> html = """<html>
    <head>
        <title>Hello World!</title>
    </head>
    <body>
        <p>Good morning</p>
    </body>
</html>"""
>>> minified = htmlmin(html)
>>> print minified
'<html><head><title>Hello World!</title></head><body><p>Good morning</p></body></html>'

Development

Add a minification test

To add a minification test, simply add the html code as test_name.html and its minified version as test_name-minified.html in test/html.

Test

Test the package:

$ python -m unittest discover

Automatic testing in various environments:

$ tox

Release

Use bumpr to release the package:

$ bumpr -b -m
[...]
$ python setup.py sdist bdist_wheel upload

Other projects

License

python-diminuendo is published under a BSD 3-clause license, see the LICENSE file distributed with the project.

Release History

Release History

0.1.1

This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.1.0

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
python_diminuendo-0.1.1-py2-none-any.whl (6.7 kB) Copy SHA256 Checksum SHA256 2.7 Wheel Mar 19, 2015
python-diminuendo-0.1.1.tar.gz (6.1 kB) Copy SHA256 Checksum SHA256 Source Mar 19, 2015

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting