[gedit/wip/code-conventions] Write code conventions to the hacking file
- From: Sébastien Wilmet <swilmet src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gedit/wip/code-conventions] Write code conventions to the hacking file
- Date: Wed, 8 Jan 2014 21:24:49 +0000 (UTC)
commit 8664e3b63e28980b8d6085870620853e3b3bde73
Author: Sébastien Wilmet <swilmet gnome org>
Date: Wed Jan 8 22:21:58 2014 +0100
Write code conventions to the hacking file
And some other links that may be useful.
HACKING | 27 +++++++++++++++++++++++++++
1 files changed, 27 insertions(+), 0 deletions(-)
---
diff --git a/HACKING b/HACKING
index 9d1c552..a816d47 100644
--- a/HACKING
+++ b/HACKING
@@ -84,6 +84,33 @@ tracker reference if applicable) and so forth. Be concise but not too brief.
git commit -a --author "Joe Coder <joe coder org>" and --signoff.
+Code conventions
+================
+
+You may encounter old code that doesn't follow all the following code
+conventions, but for new code it is better to follow them, for consistency.
+
+ - Avoid trailing whitespace.
+
+ - Indent the C code with tabulations with a width of eight characters.
+
+ - The files should have a modeline for the indentation style.
+
+ - All blocks should be surrounded by curly braces, even one-line blocks. It
+ spaces out the code, and it is more convenient when some code must be added
+ or removed without the need to add or remove the curly braces.
+
+ - Follow the C89 standard. In particular, no "//"-style comments.
+
+
+See also
+========
+
+https://wiki.gnome.org/Apps/Gedit/DevGettingStarted
+https://wiki.gnome.org/Projects/GTK%2B/BestPractices
+ftp://ftp.gnome.org/pub/GNOME/teams/docs/devel/guides/programming_guidelines/
+
+
Thanks,
The gedit team.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]