Just use these two guides from Heroku:
var testsContext = require.context(".", true, /_test$/); | |
testsContext.keys().forEach(testsContext); |
# virtual environments | |
venv | |
# Python files | |
*.pyc | |
__pycache__ | |
# Python Notebook dot files | |
.ipynb* |
root = true | |
# Unix-style newlines with a newline ending every file | |
[*] | |
charset = utf-8 | |
end_of_line = lf | |
insert_final_newline = true | |
trim_trailing_whitespace = true | |
# Python settings |
export PIP_REQUIRE_VIRTUALENV=true | |
gpip(){ | |
PIP_REQUIRE_VIRTUALENV="" pip "$@" | |
} | |
test -f /usr/local/bin/virtualenvwrapper.sh && source /usr/local/bin/virtualenvwrapper.sh | |
if which pyenv > /dev/null ; then eval "$(pyenv init -)"; fi |
SECRET_KEY=13dfdasfaw3rarfdafjpj*(*&YO&D&FAFAHUH | |
DEBUG=true | |
ALLOWED_HOSTS=localhost 0.0.0.0 127.0.0.1 | |
DATABASE_URL=postgres://user:password@localhost:5432/database |
The easiest way I have found to install PostgreSQL on Mac OSX is by using Postgres.app.
- Move the downloaded file to ~/Applications
- Double click
For new versions of Mac OSX (10.12+), you will most likely run into some errors. To avoid that, install XCode found here
https://sourceforge.net/projects/git-osx-installer/files/
git config --global user.name "[Full Name]"
A Virtual Environment is a tool to keep the dependencies required by different projects in separate places, by creating virtual Python environments for them. It solves the “Project X depends on version 1.x but, Project Y needs 4.x” dilemma, and keeps your global site-packages directory clean and manageable.
For example, you can work on a project which requires Django 1.3 while also maintaining a project which requires Django 1.0.
I highly recommend using virtualenvwrapper, it makes your life so much easier!
- Install pip