← Back to team overview

openerp-expert-framework team mailing list archive

Re: standardized xml formatting

 

Hi,
I think formatting conventions for XML would be useful - the conventions
we have for Python certainly are.
Of course that makes searching the version history harder, but it's
worth it IMHO.

Here are my humble preferences:
I like formatting conventions scripts (XML and Python) - it can be done
easily and often.
The related changes should always be committed on their own - never
change formatting and something else in the same commit, that's a real
mess.
This formatting could be done wisely by the release team when a release
is prepared - this way we all know when to expect this kind of changes.

Lionel.

Le mardi 18 mai 2010 à 18:19 +0200, Ferdinand Gassauer a écrit : 
> Hi experts!
> 
> xml files are currently not formatted following a unified coding guideline and 
> extremly difficult to read
> 
> we propose to format all xml files using the attached style sheet.
> the attached script must be adapted to local directory structure
> saxon must be installed
> 
> For quick comparison see the attached account_view xml files
> 
> what it does:
> * 2 spaces indent (makes deep structures more readable)
> * breaks contents of fields like button, menu etc and column names with 
> typically long - and hence not readable - attributes (on change, colors, 
> attrs, ... ) in new lines, which are sorted alphabetically (see line 90 of 
> xslt)
> 
> To be discussed - why do we need multiple &quot can't this be replaced by 
> multiple " or ' ? see line 75 of formatted xml
> 
> _______________________________________________
> Mailing list: https://launchpad.net/~openerp-expert-framework
> Post to     : openerp-expert-framework@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~openerp-expert-framework
> More help   : https://help.launchpad.net/ListHelp





References