1 Patch guidelines This section lists some guidelines for writing a good patch which is more likely to be accepted. Any new features or large scale work should first be discussed on the evolution-hackers list first. This will ensure the idea fits in the direction we wish to take Evolution, and also that the effort is not duplicated. See section 3 for details on the mailing lists. 1.1 Patch basics o The patch should apply cleanly at the time it is made. o It must compile once applied. o It must not generate any more compile time warnings than were already there. This may be platform dependent so simply do your best. o It must conform to C89/C90 (ANSI/ISO C), and build with gcc using the default compile flags. The primary trap is that in C99 you may define variables anywhere in the code, in C89 they must be declared in a declaration block which follows any block start '{'. If you wish to ensure the code is C89, try the following. From the gcc manual page: "To select this standard in GCC, use one of the options `-ansi', `-std=c89' or `-std=iso9899:1990'; to obtain all the diagnostics required by the standard, you should also specify `-pedantic'" ... You may actually have to use '-std=gnu89' if libraries have taken advantage of gcc extensions and where not compiled similarly, as the above options will disable all gnu extensions. [FIXME: Add the same option for Forte here] o It should not add any extra debug printing by default, unless the patch is specifically to add extra debug printing. o It should not use any gcc extensions, except where they are properly checked for and not used with other compilers. glib provides some of these features as portable macros and should be used when they cover the required functionality. o It must include ChangeLog entries in the appropriate ChangeLog for the file modified. Use emacs, C-4-a will start a properly formatted ChangeLog entry in the correct ChangeLog file automatically. o If it is from a bug report, it must reference the bug number, and if it isn't in the gnome bugzilla, it must reference the bug system from whence it came. 1.1 GUI changes If the change requires non-trivial user interface changes, then they will have to be discussed and approved on the evolution-hackers list first. This is highly recommended before embarking on any UI work, or large scale work in general. The Gnome HIG document is the place to start on any UI changes or additions. 1.2 Translated string changes Any changes to translated strings in a stable release must be discussed on the hackers list (see section 3), and/or as part of the patch submission. There must be very good reasons for changing the strings in this case. 1.3 Coding style Generally the coding style employed matches the "Linux Kernel" style, that is, basically K&R style indenting with 8 space tabs. Tabs should be used rather than space characters. Reformatting of otherwise unchanged code is not acceptable. Editors should have any automatic reformatting features disabled. K&R style indenting puts braces on the same line. The opening parenthesis of a function call or conditional statement should be on the same line as the function. "else" "} else" and "} else {" must always occur on lines by themselves. A single blank line should follow {} blocks (if not immediately followed by the close of another block), and conditional statements, and be used to separate logical groups of statements in the same block. A single blank line only should separate functions, and other structures at the top level of the file (i.e. outside functions). The same rule applies to variable declarations at the start of a block. An example of the most-developer-preferred formatting: TheType the_function (int frank) { int a = 1; if (a == frank) { a = foo (a); } else { do { a = bob (frank) + a; } until (a == frank); frank = a; } return (TheType) a; } Where there are slight stylistic differences, the style in the surrounding code should be followed. 1.3.1 Object casts You can either use C style casts, or Gtk style casts. Note that Gtk style casts can add significant execution overhead, which is not adding any extra checking. e.g. if arguments have already been type-checked by preconditions. Putting a space between a cast and a variable is optional, but preferred by most of the developers. 1.3.2 Preconditions External api entry points should have preconditions (g_return_if_fail, etc), although their use varies from case to case. Internal entry points and/or when you are guaranteed the type has already been checked, are unecessary. Object initialisation and other virtual method invocations are considered internal entry points. 1.3.3 Line lengths Do not expend effort and resort to unreadable formatting merely to fit any long lines into 80 column widths. We use 8 space tabs, and because of the lack of namespacing other than extending the function name, many of the function and type names are too long for this to be practical. We now all uses high resolution displays, and not circa-80's VT100 terminals! On the other hand, lines should generally not exceed 100 characters, and absolutely not exceed 160 characters. If your tab nesting is too deep you probably have a poor design that needs rethinking. 1.4 Design This is a tricky issue to document, but the design of new code should `fit' with the existing design of the relevent module. It should at the very least, be no worse. Code should not cross existing abstraction boundaries or attempt to remove or work around them, if required the existing design may need adjustment. Type and method names should follow the existing practice in the surrounding code. Method arguments should follow the same order as related methods, and should use the same names for matching parameters. Per file, static class globals are ok, true globals may be ok, but should be used sparingly. Use 'i' for a loop variable, if that's all it is, don't use 'the_current_index'. etc. If in doubt, ask on the lists. 2. Patch submission guidelines This section outlines procedures that should be followed when submitting patches for Evolution. The patch must simply be attached to an appropriate, open bug on bugzilla.gnome.org. For discussion of the patch, or to expediate processing of the patch, an email may be sent to the evolution-patches list. See the mailing lists section for more information. You may attach patches when sending to this list for discussion. Any non-trival patches (patches of more than 1 or 2 changed lines in more than 5 isolated locations) also require copyright assignment. See http://developer.ximian.com/projects/evolution/copyright.html for details. If you follow the guidelines listed here, you should generally expect a response within 2 working days. If you re-send the same patch repeatedly, you will more likely receive less attention. Do not re-send the same patch repeatedly. 2.1 Subject Lines If the patch addresses a specific bug in bugzilla.gnome.org, then the bug number must be included in the subject line, preferably near the beginning of the subject line. A concise summary of the bug(s) being addressed, should be the remainder of the subject. It is unnecessary to add "[PATCH]", "patch" or similar to the subject line, unless it is being cross-posted to other non-patch lists. It is absolutely unnecessary to add "please consider", "please review", or "seeking review", or similar, to the subject line. Please do not do this. Where the patch does not address a specific bug number, then the subject line should simply be a concise summary of the problem/feature it addresses. In all cases the subject line should include the module(s) to which the patch applies, and would generally match the component on the bug or the top-level module directory (e.g. camel, mail, addressbook, use 'all' for more than 3 or 4 modules). 2.2 Message Body Patches should be attached as attachments, preferably as a single diff, when possible, and the changes are related. The diff must be in unified diff format, "-up" is a suitable argument to give to "cvs diff" (-p may be dropped if not supported by your diff). If you have added files, then -N should also be used, but if you are using cvs, "cvs add" is needed, and requires write access to the repository. If the patch does not address a specific bug, then the patch email should describe which feature or problem it addresses. If it does address a specific bug, then further explanation beyond the bug commentary is optional, although often convenient. It would also be helpful to summarise the module to which it applies in the message body. In all cases you should include which branch, or branches, the patch is intended to apply to. If this is not given it will be assumed to be the trunk (HEAD), and such patches will and must not be applied to any stable branch without further approval. 2.3 Stable branches Generally, any patch to the stable branch from non-core developers must address a specific bug in bugzilla.gnome.org. The patch should also be attached to the bug in question. The patch must not be applied until reviewed. 3 Mailing lists 3.1 Evolution Hackers If you wish to discuss patches before they are submitted, or ideas before you start to work on them, do it on the evolution-hackers list, which may be subscribed and viewed at `http://lists.ximian.com/mailman/listinfo/evolution-hackers'. This is a low-volume list (5-10 posts per day on average). Some patches may be discussed here to get a wider audience, although once a patch has been made it should generally be discussed on evolution-patches. Large posts are blocked, so they should be sent to the patches list intsead, or reference resources elsewhere. Feature requests, bug reports, and other user related discussions, without the intention to write code to address them, will be ignored. 3.2 Evolution Patches The patch discussion list evolution-patches may be subscribed and viewed at `http://lists.ximian.com/mailman/listinfo/evolution-patches'. Once a patch has been written, it may be submitted here for discussion, as well as final approval. Patches may be sent to this list as attachments for discussion. Any non-patch related postings to this list will be ignored. 6-40/+236 * Revert my last patch.Srinivasa Ragavan2008-01-202-1/+5 * Take off the cursor/focus. Now we have a nice cairo rendered message listSrinivasa Ragavan2008-01-202-1/+6 * ** Fix for bug #507564Djihed Afifi2008-01-152-18/+64 * Patch from David Turner <cillian64@googlemail.com> ** Partial fix for bug #4...Suman Manjunath2008-01-142-2/+9 * ** Fix for bug #488213Milan Crha2008-01-122-1/+8 * ** Fix for bug #448441Milan Crha2008-01-103-7/+71 * ** Fix for bug #339813Milan Crha2008-01-072-0/+8 * Patch from Michael Monreal <michael.monreal@gmx.net>: Fix for bug #492188 (U...Suman Manjunath2008-01-072-1/+10 * Patch from Christian Krause <chkr@plauener.de>: Fix for bug #506772 (Not-NUL...Suman Manjunath2008-01-072-1/+8 * ** Fixes bug 474651Tobias Mueller2007-12-141-1/+1 * ** Fix for bug #501969 Passwords should not be forgotten for all errorsSankar P2007-12-112-1/+11 * ** Fixes bug 474651Tobias Mueller2007-12-101-0/+1 * Patch from David Turner <cillian64@googlemail.com>: Fix for bug #468277 (mis...Suman Manjunath2007-12-072-1/+8 * Corrected misspelled instances of vCard in:Suman Manjunath2007-12-066-11/+25 * ** Fixes bug #489652Matthew Barnes2007-11-299-1638/+1720 * ** Fix for bug #495711Milan Crha2007-11-233-5/+23 * ** Fix for bug #495875Gilles Dartiguelongue2007-11-182-5/+14 * ** Remove trailing whitespace from source code.Matthew Barnes2007-11-1562-814/+814 * ** Remove dead files from source control. The dates below indicate whenMatthew Barnes2007-11-035-372/+11 * Remove debugging output.Priit Laes2007-11-011-2/+0 * ** Fix for bug #484064Michael Monreal2007-10-313-4/+13 * Remove unneeded include.Kjartan Maraas2007-10-312-1/+5 * Zero out the GnomePilotRecord struct to silence a compiler warning.Matthew Barnes2007-10-262-0/+7 * ** Fixes bug #489661Matthew Barnes2007-10-2510-1196/+17 * Warning fixes: - mixing code and declarations - NULL vs 0 vs FALSE/TRUE -Kjartan Maraas2007-10-2417-47/+83 * Patch by Michael Monreal <michael.monreal@gmx.net>Tobias Mueller2007-10-232-1/+9 * ** Fixes part of bug #417999Matthew Barnes2007-10-236-53/+83 * Patch by Michael Monreal <michael.monreal@gmx.net>Tobias Mueller2007-10-192-2/+10 * ** Fixes bug #437579Matthew Barnes2007-10-105-11/+26 * ** Fixes bug #477045Matthew Barnes2007-10-042-1/+8 * 2007-10-04 mcrha Fix for bug #331421Milan Crha2007-10-042-0/+12 * ** Fixes bug #469657Matthew Barnes2007-10-022-8/+11 * 2007-10-01 mcrha Fix for bug #337539Milan Crha2007-10-012-2/+12 * ** Fixes part of bug #474000Matthew Barnes2007-09-282-92/+15 * Fix for bug #461195 from Hiroyuki Ikezoe.Matthew Barnes2007-09-2811-36/+35 * ** Fixes bug #477045Matthew Barnes2007-09-288-44/+55 * 2007-09-21 mcrha Fix for bug #411125Milan Crha2007-09-213-38/+47 * Remove the --enable-file-chooser configure option.Matthew Barnes2007-09-143-83/+8 * 2007-09-07 mcrha Fix for bug #473903Milan Crha2007-09-072-1/+8 * Fix for a build break.Srinivasa Ragavan2007-09-032-1/+6 * ** Fix for bug #471791 (Move away from assert to g_ret)Srinivasa Ragavan2007-09-038-15/+27 * Update FSF address in header comments (#469886). Patch from TobiasMatthew Barnes2007-09-0271-125/+125 * Committed on behalf of Ushveen Kaur <kushveen@novell.com>Johnny Jacob2007-08-273-3/+15 * 2007-08-24 Suman Manjunath Fix for bug #440328Milan Crha2007-08-243-2/+11 * ** Fix for bug #353462Anand V M2007-08-232-2/+13 * 2007-08-16 mcrha Fix for bug #412732Milan Crha2007-08-162-0/+10 * 2007-08-06 mcrha Partial fix for bug #313221Milan Crha2007-08-062-6/+25 * 2007-08-06 mcrha Partial fix for bug #427469Milan Crha2007-08-062-3/+10 * ** Fix for bug #455799Hiroyuki Ikezoe2007-08-0412-107/+0 * ** Fix for bug #462007Hiroyuki Ikezoe2007-08-022-2/+13 * ** Fix for bug #462002Hiroyuki Ikezoe2007-07-312-1/+14 * Use g_strdup() instead of g_strdup_printf() for duplication of a stringHiroyuki Ikezoe2007-07-272-3/+8 * Plugged memory leaks.Hiroyuki Ikezoe2007-07-264-0/+11 * Plugged memory leak.Hiroyuki Ikezoe2007-07-262-0/+5 * Minor typos in strings.Claude Paroz2007-07-212-1/+5 * Fix the date. See comments in bug #353752.Hiroyuki Ikezoe2007-07-121-1/+1 * Fix for bug #353752Srinivasa Ragavan2007-07-092-1/+8 * ** Fix for bug #448568Gilles Dartiguelongue2007-07-073-1428/+1030 * ** Fix for bug #337787Hiroyuki Ikezoe2007-07-062-2/+35 * make the path to perl configurable and add addressbook/tools/csv2vcard toLaszlo (Laca) Peter2007-06-204-2/+13 * ** Fix for bug #448223 from Gilles DartiguelongueSrinivasa Ragavan2007-06-182-5/+8 * Fix for bug #448223 from Gilles DartiguelongueSrinivasa Ragavan2007-06-182-27/+8 * ** Fix for bug #445812 from Gilles DartiguelongueSrinivasa Ragavan2007-06-182-2/+8 * ** Fix for bug #325882Srinivasa Ragavan2007-06-185-4/+14 * Fixes #444248.Wang Xin2007-06-122-1/+12 * Reverted automake 1.6 breakage. Fixes bug 444747. Patch by Patch by DanielNickolay V. Shmyrev2007-06-062-3/+10 * ** Fix for bug #386503 from Matthew BarnesSrinivasa Ragavan2007-06-032-6/+11 * Fix for version removal from installed files.Srinivasa Ragavan2007-06-034-16/+22 * Removal of version information from installed filesSrinivasa Ragavan2007-06-031-0/+0 * Fix compiler warnings in addressbook folder. (#440272)Matthew Barnes2007-06-0315-101/+140 * Fix for bug #333858Srinivasa Ragavan2007-05-303-2/+21 * Don't assume the relative URI is non-NULL (#427232).Matthew Barnes2007-05-263-2/+18 * Fix for bug #417797 and #424055Srinivasa Ragavan2007-05-143-4/+21 * Fix for bug #404239 #358250Srinivasa Ragavan2007-05-144-3/+17 * ** Fixes part of bug #337616Matthew Barnes2007-05-132-0/+8 * Add Tango icons to preference window.Srinivasa Ragavan2007-05-112-2/+7 * *tools/evolution-addressbook-export-list-cards.c: Fixes 394932.Wang Xin2007-05-082-2/+9 * Don't include e-contact-print-envelope.h.Matthew Barnes2007-04-244-3/+7 * Clean up printing in Evolution (bug #426816)Matthew Barnes2007-04-2011-911/+496 * Massive code cleanup (bug #429422)Matthew Barnes2007-04-2011-78/+147 * Committing Contact Merging patch from Ebby WiselynSrinivasa Ragavan2007-04-183-6/+309 * ** Fix for bug #426743. Corrected typo "asychronous".Elizabeth Greene2007-04-102-1/+7 * change "E-Mail" to "Email". Fixes bug #404233.Andre Klapper2007-04-102-2/+7 * ** Fix for bug #426487simon.zheng2007-04-092-7/+15 * ** Fix for bug #426829.simon.zheng2007-04-093-3/+13 * Call gettext() on the EConfigItem labels. (#406933) Patch from Jeff Cai.Matthew Barnes2007-04-052-1/+10 * Don't mix declarations and code (#405495).Matthew Barnes2007-03-278-45/+51 * ** Fixes bug #419524Matthew Barnes2007-03-2124-23/+29 * ** Fixes bug #360240Matthew Barnes2007-03-173-9/+10 * Bypass the body of these functions on non-G_OS_UNIX for now as they useTor Lillqvist2007-03-013-0/+16 * ** Fix for bug #232065Srinivasa Ragavan2007-02-262-1/+50 * Fix critical warnings from typos in the glade file. Closes bug #397893.Kjartan Maraas2007-02-122-3/+9 * Print migration updates from Ebby Wiselyn.Srinivasa Ragavan2007-02-124-40/+84 * ** Fix for bug #332908Srinivasa Ragavan2007-02-092-19/+30 * ** Fixes bug #400726Matthew Barnes2007-02-092-0/+7 * Removed the obsolete function e_contact_print_preview.Chenthill Palanisamy2007-02-082-2/+0 * ** Committing Ebby Wiselyn's patch for GtkPrint API migration. 2006-01-22Srinivasa Ragavan2007-01-235-415/+348 * Fix for 389664 - Adding pilot-link 0.12 compatibility.Veerapuram Varadhan2007-01-082-6/+102 * Fixes bug #357970Matthew Barnes2006-12-044-3/+12 * Fixes #358249 Fixes #358249Francisco Javier F. Serrador2006-11-113-2/+7 * Changed the parameter passed to gal_view_minicard_attach.Devashish Sharma2006-10-164-5/+27 * ** Fixes bug#332908Ushveen Kaur2006-10-163-9/+20 * addressbook/importers/evolution-ldif-importer.cFrancisco Javier F. Serrador2006-10-153-3/+3 * Remove duplicate include. Fix some compiler warnings. Cast away a compilerKjartan Maraas2006-10-018-16/+34 * ** Fixes bug #261062Srinivasa Ragavan2006-09-292-0/+10 * ** Fix for bug #357811Srinivasa Ragavan2006-09-282-2/+8 * Fixes bug #351332Matthew Barnes2006-09-192-0/+8 * ** Fixes bug #352353Ushveen Kaur2006-09-122-0/+8 * Reverting last commit, head and stable are not branched so cannot commit stri...Devashish Sharma2006-09-071-1/+1 * Changed the comment "Do you want to overwrite it" to "Do you want to overwrit...Devashish Sharma2006-09-071-1/+1 * Get rid of this to lose this old directoryKjartan Maraas2006-08-241-7/+0 * Fixes a lot of search issues.Srinivasa Ragavan2006-08-212-16/+90 * Clean out this oneKjartan Maraas2006-08-181-15/+0 * Plug a leak.Kjartan Maraas2006-08-172-0/+6 * Fixes bug #261239Srinivasa Ragavan2006-08-172-924/+1638 * Added a callback to handle contact deletion error and corresponding errorSushma Rai2006-08-073-4/+37 * Assign proper search item ids: Fix from JohnnySrinivasa Ragavan2006-08-021-0/+5 * Assign proper search item ids in addressbook search.Devashish Sharma2006-07-271-5/+4 * Commented out reference to undefined function eab_search_dialog_new().Sushma Rai2006-07-242-1/+6 * Added support for gadu gadu im in contact entry.Devashish Sharma2006-07-244-0/+12 * Assign credits to Mikhail Zabulev.Harish Krishnaswamy2006-07-221-1/+1 * Reviewed by Harish Krishnaswamy <kharish@novell.com>Yuri Pankov2006-07-222-0/+9 * ** Fixes bug #347381Boby Wang2006-07-222-0/+11 * Autocompletion in contact list email entry.Devashish Sharma2006-07-212-11/+83 * Fix for Bug 343816Devashish Sharma2006-07-193-16/+182 * [addressbook]Ross Burton2006-07-194-15/+27 * remove "*" from translation. Fixes bug #331147.Andre Klapper2006-07-196-58/+67 * Fix for bug 332909Srinivasa Ragavan2006-07-143-48/+66 * Fixing memory leaks.Hiroyuki Ikezoe2006-07-10