From couchdb-commits-return-442-apmail-incubator-couchdb-commits-archive=incubator.apache.org@incubator.apache.org Tue Jun 03 19:12:56 2008 Return-Path: Delivered-To: apmail-incubator-couchdb-commits-archive@locus.apache.org Received: (qmail 49451 invoked from network); 3 Jun 2008 19:12:55 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 3 Jun 2008 19:12:55 -0000 Received: (qmail 29631 invoked by uid 500); 3 Jun 2008 19:12:58 -0000 Delivered-To: apmail-incubator-couchdb-commits-archive@incubator.apache.org Received: (qmail 29586 invoked by uid 500); 3 Jun 2008 19:12:58 -0000 Mailing-List: contact couchdb-commits-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: couchdb-dev@incubator.apache.org Delivered-To: mailing list couchdb-commits@incubator.apache.org Received: (qmail 29577 invoked by uid 99); 3 Jun 2008 19:12:58 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Jun 2008 12:12:58 -0700 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Jun 2008 19:12:02 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id BD1CA2388A50; Tue, 3 Jun 2008 12:12:23 -0700 (PDT) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r662860 - in /incubator/couchdb/site/htdocs/community: lists.html standards.html standards.txt Date: Tue, 03 Jun 2008 19:12:23 -0000 To: couchdb-commits@incubator.apache.org From: cmlenz@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20080603191223.BD1CA2388A50@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: cmlenz Date: Tue Jun 3 12:12:23 2008 New Revision: 662860 URL: http://svn.apache.org/viewvc?rev=662860&view=rev Log: site: Added minimal set of basic coding standards. Modified: incubator/couchdb/site/htdocs/community/lists.html incubator/couchdb/site/htdocs/community/standards.html incubator/couchdb/site/htdocs/community/standards.txt Modified: incubator/couchdb/site/htdocs/community/lists.html URL: http://svn.apache.org/viewvc/incubator/couchdb/site/htdocs/community/lists.html?rev=662860&r1=662859&r2=662860&view=diff ============================================================================== --- incubator/couchdb/site/htdocs/community/lists.html (original) +++ incubator/couchdb/site/htdocs/community/lists.html Tue Jun 3 12:12:23 2008 @@ -86,11 +86,11 @@

The archives for this list can also be browsed online.

@@ -105,11 +105,11 @@

The archives for this list can also be browsed online.

@@ -122,9 +122,9 @@

Replies to commit mails should be directed to the couchdb-dev mailing list.

Modified: incubator/couchdb/site/htdocs/community/standards.html URL: http://svn.apache.org/viewvc/incubator/couchdb/site/htdocs/community/standards.html?rev=662860&r1=662859&r2=662860&view=diff ============================================================================== --- incubator/couchdb/site/htdocs/community/standards.html (original) +++ incubator/couchdb/site/htdocs/community/standards.html Tue Jun 3 12:12:23 2008 @@ -69,6 +69,28 @@

Coding Standards

+ +

CouchDB comes with code in a variety of different languages. While the core is +written in Erlang, there are some parts written in C, others written in HTML, +CSS, and Javascript, and then there are also shell scripts, Makefiles, et +cetera.

+ +

First, some general rules:

+ +
    +
  • Always use spaces for indentation, not tabs, except in Makefiles.
  • +
  • Use four spaces for indentation in Erlang and C code, two spaces in HTML, +CSS, and Javascript.
  • +
  • Try to keep lines shorter than 80 characters.
  • +
  • When you edit a file, try to stick with the conventions used in the +surrounding code.
  • +
  • Avoid mixing purely cosmetic changes (such as removing trailing white-space) +with functional changes, as that makes review of the actual change (whether +it’s a check-in or a patch) much more difficult.
  • +
+ +

For more detailed coding conventions for Erlang code, please see the Erlang +Programming Rules and Conventions.