summaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorjomo <github@jomo.tv>2014-07-16 00:33:43 +0200
committerjomo <github@jomo.tv>2014-07-16 00:33:43 +0200
commit1430a454ed18ac3a815cc4d39c7dffd2e6ac9e90 (patch)
tree493cbf18f33d635e7b3123438d8857f8544726c2 /README.md
parentd2ec8b6d3f2d0804dbf52e7931cb589e9b323acd (diff)
removed camelcase, added more coding style to readme
Diffstat (limited to 'README.md')
-rw-r--r--README.md27
1 files changed, 27 insertions, 0 deletions
diff --git a/README.md b/README.md
index 64ea7d0..8f374a7 100644
--- a/README.md
+++ b/README.md
@@ -151,6 +151,33 @@ Use 2 spaces to indent.
Always use double-quotes!
Only use single-quotes when the string contains double-quotes that would need to be escaped.
+## Capitalization
+Do not use camelCase for variable or function names! Use under_score naming.
+
+## Aligning variable assignments
+In case you have multiple variable assignments, align the equals sign:
+
+```Python
+# bad
+foo = 1
+foobar = 2
+a = 3
+
+# good
+foo = 1
+foobar = 2
+a = 3
+```
+
+## Vertical spacing
+Use at least one space left and one space right to equals signs, and one space right to colons.
+
+## Horizontal spacing
+Leave two empty lines before function definitions. In case you need to use `@hook.something`, add the two lines before that, directly followed by the definition.
+
+## Meaningful names
+Give function and variable names meaningful names. If you want to shorten long names, that's fine, but leave a comment on assigment with the actual meaning.
+
## Comments
Comments are good!
Please comment everything that's non-obious or makes it easier to understand