Skip to content

Instantly share code, notes, and snippets.

@dbrack
Last active May 16, 2016 18:32
Show Gist options
  • Save dbrack/a66e5abae0db93b58d22f1de1b0d9040 to your computer and use it in GitHub Desktop.
Save dbrack/a66e5abae0db93b58d22f1de1b0d9040 to your computer and use it in GitHub Desktop.

Revisions

  1. dbrack renamed this gist May 16, 2016. 1 changed file with 0 additions and 0 deletions.
    File renamed without changes.
  2. dbrack revised this gist May 16, 2016. 1 changed file with 0 additions and 1 deletion.
    1 change: 0 additions & 1 deletion virtual-env.md
    Original file line number Diff line number Diff line change
    @@ -10,7 +10,6 @@
    ```
    # virtualenvwrapper
    export WORKON_HOME=~/.virtualenvs
    export PROJECT_HOME=~/Files/Projects
    source /Library/Frameworks/Python.framework/Versions/2.7/bin/virtualenvwrapper.sh
    export PIP_VIRTUALENV_BASE=$WORKON_HOME
    export PIP_RESPECT_VIRTUALENV=true
  3. dbrack revised this gist May 16, 2016. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion virtual-env.md
    Original file line number Diff line number Diff line change
    @@ -19,7 +19,7 @@ Restart Shell/Terminal

    **Create virtual env**

    mkvirtualenv --distribute venv-name
    `mkvirtualenv --distribute venv-name`

    **Add Django Project to PythonPath for your venv**

  4. dbrack revised this gist May 16, 2016. 1 changed file with 3 additions and 3 deletions.
    6 changes: 3 additions & 3 deletions virtual-env.md
    Original file line number Diff line number Diff line change
    @@ -7,14 +7,14 @@
    `pip install virtualenvwrapper`

    **Add the following to your .zshrc/bashrc**

    ## virtualenvwrapper
    ```
    # virtualenvwrapper
    export WORKON_HOME=~/.virtualenvs
    export PROJECT_HOME=~/Files/Projects
    source /Library/Frameworks/Python.framework/Versions/2.7/bin/virtualenvwrapper.sh
    export PIP_VIRTUALENV_BASE=$WORKON_HOME
    export PIP_RESPECT_VIRTUALENV=true

    ```
    Restart Shell/Terminal

    **Create virtual env**
  5. dbrack revised this gist May 16, 2016. 1 changed file with 4 additions and 3 deletions.
    7 changes: 4 additions & 3 deletions virtual-env.md
    Original file line number Diff line number Diff line change
    @@ -2,12 +2,13 @@

    **Install virtualenv/virtualenvwrapper**

    pip install virtualenv
    pip install virtualenvwrapper
    `pip install virtualenv`

    `pip install virtualenvwrapper`

    **Add the following to your .zshrc/bashrc**

    # virtualenvwrapper
    ## virtualenvwrapper
    export WORKON_HOME=~/.virtualenvs
    export PROJECT_HOME=~/Files/Projects
    source /Library/Frameworks/Python.framework/Versions/2.7/bin/virtualenvwrapper.sh
  6. dbrack revised this gist May 16, 2016. 1 changed file with 18 additions and 13 deletions.
    31 changes: 18 additions & 13 deletions virtual-env.md
    Original file line number Diff line number Diff line change
    @@ -1,10 +1,11 @@
    #Python virtual env / Django OS X
    Install virtualenv/virtualenvwrapper

    **Install virtualenv/virtualenvwrapper**

    pip install virtualenv
    pip install virtualenvwrapper

    Add the following to your .zshrc/bashrc
    **Add the following to your .zshrc/bashrc**

    # virtualenvwrapper
    export WORKON_HOME=~/.virtualenvs
    @@ -15,27 +16,31 @@ export PIP_RESPECT_VIRTUALENV=true

    Restart Shell/Terminal

    Create virtual env
    **Create virtual env**

    mkvirtualenv --distribute venv-name

    Add Django Project to PythonPath for your venv
    **Add Django Project to PythonPath for your venv**

    ```
    cd projectname && add2virtualenv `pwd`
    ```

    **Activate virtualenv**

    `workon venv-name`

    Activate virtualenv
    **Install Software via pip**

    workon venv-name
    `pip install Django`

    Install Software via pip

    pip install Django
    pip install https://www.djangoproject.com/download/1.5c1/tarball/
    `pip install https://www.djangoproject.com/download/1.5c1/tarball/`

    Dump dependencies
    **Dump dependencies**

    pip freeze > requirements.txt
    `pip freeze > requirements.txt`

    Install dependencies in production
    **Install dependencies in production**

    pip install -r requirements.txt
    `pip install -r requirements.txt`
  7. dbrack created this gist May 16, 2016.
    41 changes: 41 additions & 0 deletions virtual-env.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,41 @@
    #Python virtual env / Django OS X
    Install virtualenv/virtualenvwrapper

    pip install virtualenv
    pip install virtualenvwrapper

    Add the following to your .zshrc/bashrc

    # virtualenvwrapper
    export WORKON_HOME=~/.virtualenvs
    export PROJECT_HOME=~/Files/Projects
    source /Library/Frameworks/Python.framework/Versions/2.7/bin/virtualenvwrapper.sh
    export PIP_VIRTUALENV_BASE=$WORKON_HOME
    export PIP_RESPECT_VIRTUALENV=true

    Restart Shell/Terminal

    Create virtual env

    mkvirtualenv --distribute venv-name

    Add Django Project to PythonPath for your venv

    cd projectname && add2virtualenv `pwd`

    Activate virtualenv

    workon venv-name

    Install Software via pip

    pip install Django
    pip install https://www.djangoproject.com/download/1.5c1/tarball/

    Dump dependencies

    pip freeze > requirements.txt

    Install dependencies in production

    pip install -r requirements.txt