From 43688b4df93456f0f5137dd332dff94591a4d93d Mon Sep 17 00:00:00 2001 From: Andy Allan Date: Mon, 13 Dec 2010 11:00:20 +0000 Subject: [PATCH] Write down the coding standards that we've been using up to now --- net/systemeD/halcyon/CODING.txt | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 net/systemeD/halcyon/CODING.txt diff --git a/net/systemeD/halcyon/CODING.txt b/net/systemeD/halcyon/CODING.txt new file mode 100644 index 00000000..a45919eb --- /dev/null +++ b/net/systemeD/halcyon/CODING.txt @@ -0,0 +1,28 @@ +== Coding guidelines == + +* Be sensible +* Be tolerant + +== Whitespace == + +* Use space, not tabs. You can only get away with tabs if your name is Richard Fairhurst +* Set your editor to treat tabs as two spaces when viewing them, otherwise you'll go mad +* Blank lines shouldn't have whitespace +* No trailing whitespace +* Only "fix" whitespace errors while changing that line of code for other reasons. Otherwise, it's not worth fixing. + +== Indentation == + +package net.systemed.potlatch2.indentation { + + class IndentedByFourSpaces { + + public function IndentedByFourMoreSpaces:void { + if (indentedCodeWithinFunction) { + justIndentByTwoSpaces = true; + } else { + shotAtDawn = true; + } + } + } +}