Skip to main content

Logs things in color and beautiful format.

Project description


Logs things (dicts, tuples, lists, etc) in color and beautiful format.


This package can be installed from PyPI using `pip`. Make sure you have `pip`
installed then run:

$ pip install prettylogger

#####Installation Using Buildout

If you're using Buildout and want to use prettylogger you can do so by adding
the following lines to your `buildout.cfg` file:

recipe = zc.recipe.egg
eggs = prettylogger

and appending `prettylogger` to your `buildout:parts`.


Logging beautifully formatted things is as easy as:

from prettylogger.utils import log

thing = {'name': 'prettylogger', 'version': '0.1.0'}
mode = 'rb' # Discussion below
log(thing, mode)

And it will log the following:

![prettylogger output]( "prettylogger output")

#####Formatting Options

The `mode` parameter for the `log` function is a string with each character
being one of the following:

- `p`: print the thing in purple
- `c`: print the thing in cyan
- `y`: print the thing in yellow
- `g`: print the thing in green
- `r`: print the thing in red
- `b`: print the thing in bold characters

So the `mode` used in the example above, `rb`, tells the `log` method to print
the thing in color red and bold characters.


To contribute to this mini-project just fork this repository, clone your forked
repository and run buildout inside the project directory.

$ git clone
$ cd prettylogger
$ ./bin/buildout

This will take care of retrieving the project's dependencies.

When contributing new code to the project, please test your code. The test specs
are in the `src/prettylogger/` file. To run the tests simply do:

$ ./bin/test

Merging your code into this main repository must be done through pull requests.

####Bugs and Issues

If you find any bugs and issues in this project, please report them by opening
an issue here.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

prettylogger-0.1.0.tar.gz (2.7 kB view hashes)

Uploaded source

Built Distribution

prettylogger-0.1.0-py2.7.egg (4.9 kB view hashes)

Uploaded 2 7

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page