[TYPO3-50-general] XML schema for PackageInfo.xsd
David Bruehlmeier
typo3 at bruehlmeier.com
Mon Mar 17 09:21:52 CET 2008
Hi,
I would like to suggest an XML schema for the PackageInfo.xsd file. It
would be very helpful for me to implement the XML import/export for the
FLOW3 Development Environment, but I think it would generally be a good
idea to agree on a schema for this file.
Please have a look at the schema and give me feedback:
http://www.bruehlmeier.com/fileadmin/flow3/PackageInfo.xsd
The schema is quite permissive. The only required element is the package
key. Most types are just xs:strings.
The schema introduces the following changes. What do you think?
1. Introduce the namespace
xmlns="http://typo3.org/ns/2008/flow3/PackageInfo"
2. Introduce a "version" attribute in the root element "packageInfo"
3. Rename the element "packageKey" to "key" (DRY, it's already not
"packageVersion" but "version", etc.)
3. Introduce a new element "state" after "version" which is defined by
an enmueration to be "Experimental", "Alpha", "Beta", "Stable" or "Obsolete"
4. Allow more than one category to be assigned (That's one thing that
always bugged me about the categorization in TYPO3, because sometimes
more than one category fit. This way, it's more like "tagging" the
package with all the categories that apply).
5. Allow more than one author and "normalize" the author element (see
example below)
6. The attribute for defining a minimal version of a constraining
package currently is "atLeastVersion". I think there should also be a
way to define the maximum version. Therefore, I suggest renaming these
attributes to "minVersion" and "maxVersion".
7. Split the contraints into FLOW3 packages and system constaints such
as available programming languages, operating system, memory, etc.
These changes would lead to a PackageInfo.xml file that looks like this:
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<packageInfo xmlns="http://typo3.org/ns/2008/flow3/PackageInfo"
version="1.0">
<key>TestPackage</key>
<title>Test Package</title>
<description>The test package to demonstrate the features of
PackageInfo.xml</description>
<version>0.0.1</version>
<state>Alpha</state>
<categories>
<category>System</category>
<category>Testing</category>
</categories>
<authors>
<author>
<name>David Brühlmeier</name>
<email>typo3 at bruehlmeier.com</email>
</author>
<author>
<name>John Smith</name>
<email>john at smith.com</email>
<company>Smith Ltd.</company>
</author>
</authors>
<constraints>
<depends>
<package minVersion="1.0.0" maxVersion="1.9.9">FLOW3</package>
<system type="ProgrammingLanguage" minVersion="5.1.0">PHP</system>
</depends>
<conflicts>
<system type="OperatingSystem" minVersion="Vista">Windows</system>
</conflicts>
<suggests>
<system type="RAM">16MB</system>
</suggests>
</constraints>
</packageInfo>
Regards, Dave
More information about the TYPO3-project-5_0-general
mailing list