summaryrefslogtreecommitdiff
path: root/HACKING
blob: 604c2ba2749299680e194aaaeb9f77cee8f7ef70 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
In order to keep the code nice and clean we have a few requirements you'll
need to stick to in order to get your patch accepted:

- Use 2-space no-tabs for indentation (mandatory on new files, old
  ones will be re-indented eventually. When modifying an existing file
  with 8-space indentation keep the old style please).

- Use K&R style for the braces.

- No braces for one line control clauses.

- Callback functions have a suffix _cb.

- All files have to be encoded in UTF-8.

- Use char/int/double/..., not gchar/gint/gdouble/... types.

- All implementation files must include first "config.h", followed by
  the primary header, followed by a blank line, followed by all the
  local headers sorted alphabetically, followed by a blank line,
  followed by all the system headers sorted alphabetically.

  Headers should follow the same pattern excluding the config.h and
  self file section, for obvious reasons.

- Make comments full sentences. This means proper capitalization and
  punctuation.

- data/kr-gnome-indent.cfg is provided as a reference config file for the
  uncrustify program to get correct indentation in new files.

- There's no space between a type cast and the variable name.

  Right: (int *)foo
  Wrong: (int*) foo

See ChangeLog.README for Git checkin rules.
See doc/debugging.txt for some tips and tricks for debugging.

Do NOT commit to this module without permission from a maintainer.
See epiphany.doap for who they are.