[isf-wifidog] For developers: changes for new documentation
Max Horváth
max.horvath at maxspot.de
Lun 19 Déc 20:24:59 EST 2005
Hello developers,
before commiting any changes to the CVS I'd like to inform you about
what I changed and why I did it.
This change will take place in every file.
Well, so what did I do?
I added a new directory "docs". It contains a first version of a
PEAR::PhpDocumentor 1.3.0RC5 compilation.
We all know that WiFiDogs lacks regarding documentation. So I thought
now that almost no developers commits anything new to the CVS might
be the perfect moment to change a lot of files.
To get as less as possible errors and warnings regarding the
documentation compilation the first I had to change were the headers
of every PHP file.
The PHPdoc documentation will be very usefull for everyone. Right now
it just contains information for the developers, but we could and
should include information for the endusers (administrators of auth
servers) in it. But this will be a next step.
During touching every file I also started to convert leading tabs
into spaces.
As I didn't found any coding standards for WiFiDOG I'd like to decide
on it. But we shouldn't reinvent the wheel.
We should be using the PEAR coding standards.
http://pear.php.net/manual/en/standards.php
Here are the most important facts:
- use an indent of 4 spaces, with no tabs
- control statements should have one space between the control
keyword and opening parenthesis, to distinguish them from function calls
- you are strongly encouraged to always use curly braces even in
situations where they are technically optional
- functions should be called with no spaces between the function
name, the opening parenthesis, and the first parameter; spaces
between commas and each parameter, and no space between the last
parameter, the closing parenthesis, and the semicolon
- complete inline documentation comment blocks (docblocks) must be
provided
- include the $Id$ CVS keyword in each file. As each file is edited,
add this tag if it's not yet present (or replace existing forms such
as "Last Modified:", etc.)
The only difference should be that we use UTF-8 character encoding -
not ISO-8859-1 character encoding.
Well, till now I did the following:
- I replaced leadings tabs with 4 spaces
- I replaced the headers of the PHP files, because they caused
problems with PHPdoc and because now they include $Id$
What I ask now is you permission to commit those changes to the CVS.
Next I ask you to translate every french PHPdoc into english. Later
I'd like to ask you to rename french function names, too - but that's
for later.
This step should lead to a better development environment for
developers not from Montreal.
Cheers, Max!
More information about the WiFiDog
mailing list