Update changelog - http cloning is waaay faster now
[gitorious.git] / HACKING.md
blobec841486ba366873d16fbb466aae9d0f1cbc0df2
1 ## Guide to Hacking Gitorious
3 To get started you need a working Gitorious setup. Gitorious ships
4 with two scripts that gets most enough services up and running to work
5 on it. See doc/setup-dev-env-centos.sh or doc/setup-dev-env-ubuntu.sh.
6 These scripts are executable annotated walkthroughs for getting
7 Gitorious up and running. If you're on e.g. Debian, the Ubuntu script
8 should work, but you will likely need to go through it manually.
10 On a box that has no existing Ruby development environment running
11 either of the two aforementioned scripts will take about 10-15
12 minutes.
14 Alternatively, if you're OK with working through a virtual machine,
15 you can grab the fully automated installer or one of the pre-built VMs
16 from http://getgitorious.org.
18 ### Coding style
20 * Two spaces, no tabs, for indention
21 * Don't use and and or for boolean tests, instead always use && and ||
22 * MyClass.my_method(my_arg) -- not my_method( my_arg ) or my_method my_arg
23 * Unless precedence is an issue; do .. end for multi-line blocks, braces for single line blocks
24 * Follow the conventions you see used in the source already
26 (copied mostly verbatim from dev.rubyonrails.org)
28 ### Branching model
30 Gitorious uses
31 [the git-flow branching model](http://nvie.com/posts/a-successful-git-branching-model/)
32 for branching. This means that the master branch is stable, and is
33 only merged to once a feature has been completed.
35 New features are created in feature branches (named `feature/$name`)
36 and then merged into the `next` branch once finished. Such features
37 arrive in `master` as new releases.
39 When contributing new features into Gitorious as merge requests, these
40 should be started the `next` branch, and marked as such when proposed.
42 The exception to this is hotfixes, which may be started from and
43 proposed merged into `master`. Please note that hotfixes should not
44 implement new functionality.