Pretty Print JSON v2.0.3

written by Andrew Shay on 2016-11-15

Pretty Print JSON has been updated to v2.0.3.
The usage has been simplified and it is now a universal bdist wheel.
pip install pretty_print_json

Website source added to GitHub

written by Andrew Shay on 2016-11-15

This website's source has been added to GitHub.
This website is built with Lektor and HTML5 Boilerplate

Project Neuron

written by Andrew Shay on 2015-12-15

Neuron is my new project for creating Python desktop applications with web technologies.
It’s a sample project that can be downloaded and rebranded.

Portable Virtualenv for Python

written by Andrew Shay on 2015-11-14

I needed a way to create a portable virtualenv but the answers I came across online were suggesting solutions like py2exe or cxfreeze which are “too much”.
I need a simple way to make that virtualenv portable so that it can be activated anywhere.

I came up with a solution that is working well, but it has only been tested with a few Python packages.

First, create your virtualenv on the same OS that it will be deployed on.
Now you must write a script to accomplish the following goals, which will make the env portable. This script will need to run every time that the ENV is moved.

  • Create a variable called new_env which will store the path to the ENV folder’s new location, including the folder name
  • Open ENV/bin/activate and change every line that starts with VIRTUAL_ENV to reflect the new path
  • Now loop through every file in ENV/bin
  • Open the file, and if the first line starts with “#!”, it’s likely pointing to the ENV’s Python. That line needs to be rewritten to reflect the new path to Python.
  • Write the new contents back to the file

You should skip opening, “activate”, “python”, “python2” etc

That’s it. You should be able to activate the ENV.

New Tool – Pretty Print JSON

written by Andrew Shay on 2015-10-29

I have released a new, simple tool built with Python.
Pretty Print JSON allows you to easily take ugly JSON, make it pretty, then print it out (and save it)

pip install pretty_print_json
ppj -h