Xml file writing was improved.

	modified:   cmd/core/addcmd.groovy