Skip to the content
Documentation
Help Start
Reading in:
  • German: 9,199 of 9,199 pages
About the help in other languages
All help pages

Versioning your own packages

Where a package's version lives (version number and release number in package.xml, the version attribute in index.xml, the release folder on the server), how Exponential compares versions, how min-version decides…

Download as PDF

Address: https://doc.exponential.earth/exphelp/viewer/help/site-packages/your-own/versioning-your-own-packages.md

On this page

Versioning your own packages

This page is for developers who publish site packages and the packages they require, and need installations to pick the right copy. It shows every place a version is written, how the kernel reads and compares them, and how to raise them for a new release.

7x and the Exponential Foundation strongly encourage you to submit your packages by pull request to se7enxweb/exponential.packages.exponential.earth, where the release folders follow the Exponential versions: see Contribute your site package.

Contents

  1. Where versions are written
  2. How versions are compared
  3. What min-version does
  4. What the index version does
  5. Raising the version for a release
  6. Published means permanent

Where versions are written

PlaceExampleMeaning
package.xml <version><number>1.2.0the package's version number
package.xml <version><release>1the release number of that version (1 for a new package)
package.xml <changelog><entry release="...">release="1"which release a changelog entry belongs to
package.xml <require min-version="...">1.2.0-1the lowest version of a required package this one accepts
package.xml <ezpublish><version>6.0.15-stablethe Exponential version the package was made for (the element keeps its historical name)
index.xml <package version="...">1.2.0-1the version the server announces
the server folderexponential/6.0/6.0.15/the Exponential release the files were published for

eZPackage::getVersion() joins number and release as <number>-<release>; that pair is what min-version and the ezpackage table use. The version attribute of the root <package> element is something else: the kernel writes the package format version there (eZPackage::VERSION, 3.5.2) when it stores a package.

How versions are compared

kernel/classes/ezpackageversion.php (eZPackageVersion) reads a version number as Semantic Versioning 2.0.0 first:

  • MAJOR.MINOR.PATCH, with optional -prerelease and +build (build metadata is ignored when comparing);
  • older forms are still understood: fewer parts (1.0 reads as 1.0.0), more parts (1.2.3.4), a letter suffix (3.4.0beta1 is the prerelease beta1);
  • anything else is kept as text and sorts before every version that can be read.

The release number is compared last, numerically: 1.0-1 < 1.0-2 < 1.0.1-1, and 1.0-1 equals 1.0.0-1. In a <number>-<release> pair, the part after the last - is the release only when it is all digits.

New packages from the creation wizards must have a strict SemVer version of at most 24 characters (eZPackageVersion::isValidNew()); ezpm create takes the version as given. Use strict SemVer for your own packages: it is the one form every tool reads the same way.

Note

The 7x site packages still carry <number>6.0</number> and <release>15-stable</release>, a form that predates these rules. Your fork does not have to copy it: reset the version to your own first release, for example <number>1.0.0</number> and <release>1</release>.

What min-version does

When the setup wizard or the kickstarter installs a site package, downloadDependantPackages() in kernel/setup/steps/ezstep_site_types.php looks at each <require type="ezpackage">:

SituationWhat happens
the required package is not importedit is downloaded from the url of its index.xml entry and imported
it is imported with a version lower than min-version (eZPackageVersion::compareFull())the old copy is removed and the package downloaded again
it is imported with that version or higherit is used as it is
it is not in the indexthe install stops with "Download of package '...' failed. You may upload the package manually."

So raise min-version whenever your site package needs the newer content or classes; otherwise an installation that imported an older copy keeps it.

What the index version does

In the setup wizard in the browser, a site package that is both in the index and imported locally is offered from the index when the index version is higher than the local one (compareFull() in createSitePackagesList()), and the local copy is used otherwise. The kickstarter always prefers the index entry, because, as the code notes, "the package index version attribute is not comparable with the local package version". Keep the index version equal to <number>-<release> of the archive it points to, and both readings agree.

Raising the version for a release

  1. Raise <number> for a changed package (or <release> for a repackaging of the same content).
  2. Add a <changelog><entry release="..."> describing the change.
  3. Raise min-version in every package that needs the change, and their versions in turn.
  4. Rebuild the archives (Rebuilding with build.sh).
  5. Write the new versions into index.xml.
  6. Publish into the folder of the Exponential release the packages are for (Running your own package server).

Published means permanent

Once an archive is on a server, installations may have imported it under its version. Never replace a published archive with different content under the same version: publish a new version, and say in its changelog what was wrong with the previous one. A version whose last position reaches 9 goes on to 10 (1.0.9 is followed by 1.0.10); only the last position counts on. The reasoning is on A pushed tag is permanent and Only the last position counts.

Become an Exponential Partner

Partners share their information, provide funding, contribute back and develop the products with us, and that is how Exponential grows. A partner website and dashboard are planned for mid-2027: please become a partner today to speed up our growth rate and land new features faster.

Something wrong on this page? Report an error

Documentation license

This documentation is free documentation, licensed under the GNU Free Documentation License 1.3 or later.

Exponential Copyright © 1998-2026 Exponential Foundation and 7x