aboutsummaryrefslogtreecommitdiffstats
path: root/docs/tutorial/1-serialization.md
diff options
context:
space:
mode:
authorTom Christie2012-09-03 12:41:52 +0100
committerTom Christie2012-09-03 12:41:52 +0100
commit247a422a64378c968f0972b1797b919ae03296bb (patch)
treecea4d82075ea2fc5fa6300a05c147ed54c9107ec /docs/tutorial/1-serialization.md
parentc191a46ef050e6cad5b1ada679615b511f5fe69f (diff)
downloaddjango-rest-framework-247a422a64378c968f0972b1797b919ae03296bb.tar.bz2
Add virtualenv to start of tutorial
Diffstat (limited to 'docs/tutorial/1-serialization.md')
-rw-r--r--docs/tutorial/1-serialization.md17
1 files changed, 15 insertions, 2 deletions
diff --git a/docs/tutorial/1-serialization.md b/docs/tutorial/1-serialization.md
index 55a9f679..6a97f779 100644
--- a/docs/tutorial/1-serialization.md
+++ b/docs/tutorial/1-serialization.md
@@ -6,6 +6,18 @@ This tutorial will walk you through the building blocks that make up REST framew
## Getting started
+Before we do anything else we'll create a new virtual environment, using [virtualenv]. This will make sure our package configuration is keep nicely isolated from any other projects we're working on.
+
+ mkdir -p ~/.env
+ virtualenv --no-site-packages ~/.env/djangorestframework
+ source ~/.env/djangorestframework/env/bin/activate
+
+Now that we're inside a virtualenv environment, we can install our packages requirements.
+
+ pip install django
+ pip install djangorestframework
+
+Now we're ready to get coding.
To get started, let's create a new project to work with.
django-admin.py startproject tutorial
@@ -231,6 +243,7 @@ We're doing okay so far, we've got a serialization API that feels pretty similar
Our API views don't do anything particularly special at the moment, beyond serve `json` responses, and there's some error handling edge cases we'd still like to clean up, but it's a functioning Web API.
-We'll see how we can start to improve things in [part 2 of the tutorial][1].
+We'll see how we can start to improve things in [part 2 of the tutorial][tut-2].
-[1]: 2-requests-and-responses.md \ No newline at end of file
+[virtualenv]: http://www.virtualenv.org/en/latest/index.html
+[tut-2]: 2-requests-and-responses.md \ No newline at end of file