A negative list of non-feature-branches names
is already supported - this patch adds a list of
branches names which *will* be considered as
feature branches.
Allows changing the currently hardcoded set of
expected feature branch names, from:
* master|trunk|default|develop
To any set of names or patterns that you desire.
Current versions of Git output the commit hash as detached HEAD instead
of FETCH_HEAD. The VersionGuesser should be able to handle commit hashes
as well as FETCH_HEAD to detect the correct branch of a commit.
Working towards #3545.
formatVersion() does not belong in VersionParser since it depends upon a
Package object, and is creating a more complete pretty formatted
version, not parsing anything.
The new getFullPrettyVersion() method can be seen as an extension to
getPrettyVersion(), and is located in BasePackage as a result.
Callers to VersionParser::formatVersion() were not updated in this
commit to demonstrate that no functionality was changed in this
refactor. They will be updated in a follow up commit.
This is a change to the >=2.3.0 comparison. Without this change, such a
comparison will exclude pre-release versions.
The rationale is that this makes the comparison more consistent with
<2.3.0 (which excludes all pre-releases) and ~2.3.0 (which includes
pre-releases).
Instead of developing plugins against a single, fixed Plugin API version - `"composer-plugin-api": "1.0.0"`, this change will allow plugin developers to use versions like `"composer-plugin-api": "~1.1"` or `"composer-plugin-api": ">=2.1 <3.0"`, aka actual Composer-compatible constraints.
Only the "1.0", "1.0.0" and "1.0.0" Plugin API versions will be regarded as BC versions, and internally converted to "^1.0"; every other declared version string will be kept as it is.
Because of this new constraint flexibility, plugin version mismatches will be skipped, which means those plugin will NOT be registered to the system. Previously, a mismatch triggered a warning, but plugins were still registered.