Skip to content

Instantly share code, notes, and snippets.

@rg3915
Last active September 18, 2016 20:29
Show Gist options
  • Save rg3915/92ca34f69dde014b38c29bf0f48c0b30 to your computer and use it in GitHub Desktop.
Save rg3915/92ca34f69dde014b38c29bf0f48c0b30 to your computer and use it in GitHub Desktop.
How to generate graph models with Python 3
# Colors
red=`tput setaf 1`
green=`tput setaf 2`
reset=`tput sgr0`
sudo apt-get install graphviz libgraphviz-dev pkg-config
pip install pygraphviz
git clone https://github.com/nlhepler/pydot
cd pydot
python setup.py install
cd ..
rm -rf pydot
pip install django-extensions
pip install pyparsing
echo "${red}Type:${green} python manage.py graph_models -a -g -o models.png${reset}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment