[BUGS-6802] add support for pecl as source to check #14
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In https://github.com/pantheon-systems/cos-runtime-php (specifically here), we are actually using PECL as the source, but we're checking the GH mirror for versions. It's possible (see https://github.com/pantheon-systems/cos-runtime-php/pull/433 and https://github.com/php/pecl-web_services-oauth/tags as compared to https://pecl.php.net/package/oauth) that a package's version on GitHub might not match its version on PECL. This version mismatch can be confusing and problematic as we enact the Spiderman meme of figuring out which is the source of truth.
This PR adds support for checking PECL for the latest version by making a
curl
request against the PECL API'slatest.txt
-- which is actually far simpler than checking the releases/tags on GitHub. Since we're sourcing from PECL, we should be able to check the actual source for the latest versions and use that rather than checking a source that's different from where we're actually getting the extension.The actual change adds support for a new
source
param in thedependencies.yml
. Currently,github
,pecl
and null (no value) are supported withgithub
being the default if nosource
is defined. Tests and validations have been updated to support the newdependencies.yml
parameter.closes #13