Changeset 121:7d022648aa4e


Ignore:
Timestamp:
Sep 2, 2013, 2:04:11 PM (7 years ago)
Author:
Stefano Rivera <stefano@…>
Branch:
default
Message:

Dump dicts in sorted order

File:
1 edited

Legend:

Unmodified
Added
Removed
  • nagslang/yamlish.py

    r120 r121  
    5252    def _dump_dict(self, data, indent):
    5353        output = []
    54         for k, v in data.iteritems():
     54        for k, v in sorted(data.iteritems()):
    5555            output.append('%s%s:' % (' ' * indent, k))
    5656            if isinstance(v, dict):
Note: See TracChangeset for help on using the changeset viewer.