Adding a field to the profile: Difference between revisions

Undo revision 18879 by 86.51.26.15 (talk)
imported>Brittag
(Undo revision 18879 by 86.51.26.15 (talk))
 
Line 1:
{{Hacking OpenHatch}}
 
= The set-up =
I appreciate you sharing this article.Thanks Again. Really Cool. ecgkckfdcfedebke
 
[[File:Mark_bio_before.png|link=|left]]
 
 
Today, on July 4, 2011, [http://openhatch.org/people/Mark/ my OpenHatch profile] doesn't have a special field for my birthday. When I go to edit my profile, there's no place to put it in!
 
This tutorial walks you through adding that feature to the July 4, 2011 version of the OpenHatch code.
 
Together, we will change the OpenHatch source code, which builds on top of Django and Python. You'll see how to go all the way from a new feature idea to making and testing the change. On the way, you'll see how to search, study, and test your code.
 
The goal of this exercise is to show you the thought process we use when changing the website, give you confidence to try similar things on your own, and expose you to some helpful techniques that you might not know about.
 
== Skills you need ==
 
In order to do this tutorial, you need to be willing to use a terminal and willing to learn some programming. The instructions are written for GNU/Linux systems, but Mac OS users will probably find the instructions work okay. (Windows users, I'm not sure.)
 
== Getting help ==
 
If you try this and you get stuck, come come [[chat with us on IRC]]. Explain what you're doing, and what's not working, and we'll try to get you un-stuck. The same goes for if you can ''do'' the exercises but don't understand what they ''mean''.
 
 
== Getting the source ==
 
All the sample code in this walkthrough refers to version '''d56a354''' of the OpenHatch source. To make sure the code is in line with what you expect, follow the instructions on the [http://openhatch.readthedocs.org/en/latest/contributor/getting_started.html getting started with the OpenHatch code] page. But right after you do the "git clone", do these commands:
 
$ git checkout d56a354 # Switch to that revision
$ git branch tutorial # Create a branch called tutorial that points at that revision
$ git checkout tutorial # Switch into that branch.
 
Here's how you can check that it worked. Run these commands in your new ''oh-mainline'' directory, and check that they have the same output as I've recorded:
 
<b>TODO: before continuing need to setup the DB for older version of code that you are trying to run</b>
The command is: <code>python manage.py migrate #####</code>
<b>How to determine what ##### should be? (bug paulproteus on IRC)</b>
 
$ git log -1 # look at the most recent commit on the current branch
commit d56a354403026a1c3ecd634f2731e7d98a9513ff
Author: Asheesh Laroia <asheesh@asheesh.org>
Date: Wed Jun 29 11:38:31 2011 -0400
Add a config option that enables cookie sharing for Vanilla ProxyRequest-bas
 
$ git branch # see what the current branch is named.
master
* tutorial
 
 
So far, so good? Let's dive in. (If not, [[chat with us on IRC]]!)
 
So that you and I see the same things, modify my actual profile! [[Importing a data snapshot|Import a data snapshot]] from July 4, 2011 (or the most recent one before this date)!
 
= The 'What': What are we doing, again? =
Anonymous user