Miscellaneous Informations for Developers

Here you can find some uncategorized documents about related activities and software.

Commits and coding style

Why this document

In order to have good quality in our software we must make it consistent, as easy as possible to read, make sure we can spot issues as quickly as possible and, eventually, make issues easy to fix (or avoid them at all). This document provides some guidelines about the minimal rules that apply both to external patches and to our members commits.

Coding Style

Writing code for some, maybe many, is considered a form of creative activity and as such it could be made into art as you can with painting, composing music or sculpture. We are humble enough to consider our code not that good and we'll strive to make it readable. The coding style reflects that:

Indentation rules:

Comment rules:

Syntax:

Commit/patch rules

Common rules:

e.g:

wrong commit message

git commit -m "..." -a

correct commit message

git  commit -m "Cosmetics" files/that/I/just/reformatted
git-commit -m "Now with double coffee and theora bits" mediathread/*

Patch rules:

Git Tutorial addendum

Here a list of useful snippets, some are taken from sourcemage wiki as integration to the git tutorial, another useful guide is in the wine wiki

Adding a remote branch

$ git clone git://live.polito.it/var/git/libnemesi
$ cd libnemesi
$ git branch sekrit
$ git checkout sekrit
#[hack... git commit hack ...]
#now publish it!
$ git push origin sekrit

Removing a remote branch

$ git push origin :sekrit

Tracking a remote branch

$ git checkout --track -b local_name origin/remote_name

Moving modules

Sometimes because we want to move some code from application to a common library (e.g. bufferpool used by feng and felix ) we need to update our application in a certain number of steps, this is a bare promemoria.

ALWAYS WORK IN SEPARATE BRANCHES

Release steps

MUST DO

OPTIONAL

Tools TODO

This is a pro-memoria about tools we should have ready and we ALWAYS forget about.