Author: bugman Date: Tue Jun 5 18:29:53 2012 New Revision: 16677 URL: http://svn.gna.org/viewcvs/relax?rev=16677&view=rev Log: The relax save and results XML files now include subversion details in the <relax> tag. This indicates the repository version and the URL, allowing for better debugging. Modified: branches/uf_redesign/data/__init__.py Modified: branches/uf_redesign/data/__init__.py URL: http://svn.gna.org/viewcvs/relax/branches/uf_redesign/data/__init__.py?rev=16677&r1=16676&r2=16677&view=diff ============================================================================== --- branches/uf_redesign/data/__init__.py (original) +++ branches/uf_redesign/data/__init__.py Tue Jun 5 18:29:53 2012 @@ -39,7 +39,7 @@ from relax_errors import RelaxError, RelaxPipeError, RelaxNoPipeError from relax_xml import fill_object_contents, xml_to_object from status import Status; status = Status() -from version import version +import version __all__ = [ 'align_tensor', @@ -423,9 +423,15 @@ xmldoc.appendChild(top_element) # Set the relax version number, and add a creation time. - top_element.setAttribute('version', version) + top_element.setAttribute('version', version.version) top_element.setAttribute('time', asctime()) top_element.setAttribute('file_version', "2") + rev = version.revision() + if rev: + top_element.setAttribute('revision', rev) + url = version.url() + if url: + top_element.setAttribute('url', url) # Add all objects in the data store base object to the XML element. if all: