Skip to content

Commit

Permalink
Unify PHP PEAR and PECL
Browse files Browse the repository at this point in the history
  • Loading branch information
LaurentGoderre committed Jul 5, 2024
1 parent f064274 commit 1a27abc
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 16 deletions.
13 changes: 7 additions & 6 deletions PURL-TYPES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -471,16 +471,18 @@ including container images built by Docker and others:
pkg:oci/static@sha256%3A244fd47e07d10?repository_url=gcr.io/distroless/static&tag=latest
pkg:oci/hello-wasm@sha256%3A244fd47e07d10?tag=v1

pecl
pear
----
``pecl`` for PECL PHP packages:
``pear`` for PEAR and PECL PHP packages:

- The default repository is ``https://pecl.php.net/``.
- The ``namespace`` is empty.
- The default repository for PEAR is ``https://pear.php.net``. The default repository for PECL is ``https://pecl.php.net/``.
- The ``namespace`` is the channel of the package. The domain portion of the channel MUST be lowercased.
- The ``name`` is not case sensitive
- The ``version`` is the version of the package
- Examples:

pkg:pecl/[email protected]
pkg:pear/pear.php.net/[email protected]
pkg:pear/pecl.php.net/[email protected]

pub
----
Expand Down Expand Up @@ -599,7 +601,6 @@ Other candidate types to define:
- ``openwrt`` for OpenWRT packages:
- ``osgi`` for OSGi bundle packages:
- ``p2`` for Eclipse p2 packages:
- ``pear`` for Pear PHP packages:
- ``perl6`` for Perl 6 module packages:
- ``platformio`` for PlatformIO packages:
- ``ebuild`` for Gentoo Linux portage packages:
Expand Down
32 changes: 22 additions & 10 deletions test-suite-data.json
Original file line number Diff line number Diff line change
Expand Up @@ -552,27 +552,39 @@
"is_invalid": false
},
{
"description": "valid pecl purl",
"purl": "pkg:pecl/[email protected]",
"canonical_purl": "pkg:pecl/[email protected]",
"type": "pecl",
"namespace": null,
"description": "valid php pecl purl",
"purl": "pkg:pear/pecl.php.net/[email protected]",
"canonical_purl": "pkg:pear/pecl.php.net/[email protected]",
"type": "pear",
"namespace": "pecl.php.net",
"name": "APCu",
"version": "5.1.23",
"qualifiers": null,
"subpath": null,
"is_invalid": false
},
{
"description": "valid pecl purl without version",
"purl": "pkg:pecl/APCu",
"canonical_purl": "pkg:pecl/APCu",
"type": "pecl",
"namespace": null,
"description": "valid php pecl purl without version",
"purl": "pkg:pear/pecl.php.net/APCu",
"canonical_purl": "pkg:pear/pecl.php.net/APCu",
"type": "pear",
"namespace": "pecl.php.net",
"name": "APCu",
"version": null,
"qualifiers": null,
"subpath": null,
"is_invalid": false
},
{
"description": "valid php pear purl",
"purl": "pkg:pear/pear.php.net/[email protected]",
"canonical_purl": "pkg:pear/pear.php.net/[email protected]",
"type": "pear",
"namespace": "pear.php.net",
"name": "Text_Password",
"version": "1.2.1",
"qualifiers": null,
"subpath": null,
"is_invalid": false
}
]

0 comments on commit 1a27abc

Please sign in to comment.