From 61c91fd2d22c97fd942ca67f458af5dc364f5fab Mon Sep 17 00:00:00 2001
From: Bruce Momjian Last updated: Wed Mar 1 17:24:48 EST 2006 Last updated: Wed Sep 6 20:12:13 EDT 2006 Current maintainer: Bruce Momjian (pgman@candle.pha.pa.us) The most recent version of this document can be viewed at The patch should be generated in contextual diff format (diff
-c and should be applicable from the root directory. If you are
unfamiliar with this, you might find the script
- src/tools/makediff/difforig useful. (Unified diffs are only
+ src/tools/make_diff/difforig useful. (Unified diffs are only
preferable if the file changes are single-line changes and do not
rely on surrounding lines.)
@@ -199,7 +199,7 @@
"#1.16">1.16.
Other than documentation in the source tree itself, you can find
some papers/presentations discussing the code at
- http://www.postgresql.org/developer.Developer's Frequently Asked Questions (FAQ) for
PostgreSQL
-
+ "mailto:bruce@momjian.us">bruce@momjian.us)
Our standard format is to indent each code level with one tab,
- where each tab is four spaces. You will need to set your editor to
- display tabs as four spaces:
+
Our standard format BSD style, with each level of code indented
+ one tab, where each tab is four spaces. You will need to set your editor
+ or file viewer to display tabs as four spaces:
vi in ~/.exrc: @@ -367,45 +369,16 @@ more -x4 less: less -x4 - emacs: - M-x set-variable tab-width - - or - - (c-add-style "pgsql" - '("bsd" - (indent-tabs-mode . t) - (c-basic-offset . 4) - (tab-width . 4) - (c-offsets-alist . - ((case-label . +))) - ) - nil ) ; t = set this style, nil = don't - - (defun pgsql-c-mode () - (c-mode) - (c-set-style "pgsql") - ) - - and add this to your autoload list (modify file path in macro): - - (setq auto-mode-alist - (cons '("\\`/home/andrew/pgsql/.*\\.[chyl]\\'" . pgsql-c-mode) - auto-mode-alist)) - or - /* - * Local variables: - * tab-width: 4 - * c-indent-level: 4 - * c-basic-offset: 4 - * End: - */-
The tools/editors directory of the latest sources contains sample + settings that can be used with the emacs, xemacs and + vim editors, that assist in keeping to PostgreSQL coding standards. +
+ +pgindent will the format code by specifying flags to your operating system's utility indent. This article - describes the value of a consistent coding style. + describes the value of a consistent coding style.
pgindent is run on all source files just before each beta test period. It auto-formats all source files to make them @@ -704,7 +677,7 @@ http://www.cse.iitb.ac.in/dbms/Data/Papers-Other/SQL1999/ansi-iso-9075-2-1999.pdf
Some SQL standards web pages are:
-- cgit v1.2.3