Attribute ordering in REXML

Hi all!

We are using REXML to modify XML files in our project, and we experience that the attributes of all tags are always reordered. For XML files that are checked into source control, this generates unnecessary noise.

Is there a way to either keep the ordering of the tag attributes intact or choose to have a predictable ordering like alphanumerical ordering?

All help is appreciated and links are gladly accepted :slight_smile:

路路路

--
Uwe Kubosch
uwe@kubosch.no
http://kubosch.no/

https://www.google.de/search?q=rexml+attribute+ordering

->

Cheers

robert

路路路

On Mon, Dec 3, 2012 at 9:14 AM, Uwe Kubosch <uwe@kubosch.no> wrote:

Hi all!

We are using REXML to modify XML files in our project, and we experience that the attributes of all tags are always reordered. For XML files that are checked into source control, this generates unnecessary noise.

Is there a way to either keep the ordering of the tag attributes intact or choose to have a predictable ordering like alphanumerical ordering?

All help is appreciated and links are gladly accepted :slight_smile:

--
remember.guy do |as, often| as.you_can - without end
http://blog.rubybestpractices.com/

Thanks! That did the trick.

路路路

On 2012-12-03, at 09:39, Robert Klemme <shortcutter@googlemail.com> wrote:

On Mon, Dec 3, 2012 at 9:14 AM, Uwe Kubosch <uwe@kubosch.no> wrote:

We are using REXML to modify XML files in our project, and we experience that the attributes of all tags are always reordered. For XML files that are checked into source control, this generates unnecessary noise.

Is there a way to either keep the ordering of the tag attributes intact or choose to have a predictable ordering like alphanumerical ordering?

All help is appreciated and links are gladly accepted :slight_smile:

rexml attribute ordering - Google Search
xml - REXML preserve attributes order - Stack Overflow

--
Uwe Kubosch
uwe@kubosch.no