{"id":13616611,"url":"https://github.com/composer/metadata-minifier","last_synced_at":"2025-05-15T00:06:33.934Z","repository":{"id":56957091,"uuid":"355545801","full_name":"composer/metadata-minifier","owner":"composer","description":"Small utility library that handles metadata minification and expansion.","archived":false,"fork":false,"pushed_at":"2024-08-22T15:55:01.000Z","size":17,"stargazers_count":172,"open_issues_count":0,"forks_count":4,"subscribers_count":4,"default_branch":"main","last_synced_at":"2024-10-29T15:22:09.737Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/composer.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":".github/CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-04-07T12:58:59.000Z","updated_at":"2024-10-28T09:33:33.000Z","dependencies_parsed_at":"2024-10-22T13:34:00.873Z","dependency_job_id":null,"html_url":"https://github.com/composer/metadata-minifier","commit_stats":{"total_commits":4,"total_committers":2,"mean_commits":2.0,"dds":0.5,"last_synced_commit":"20554d4accbd0734deca18fa5075ba48fd5e8e57"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/composer%2Fmetadata-minifier","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/composer%2Fmetadata-minifier/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/composer%2Fmetadata-minifier/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/composer%2Fmetadata-minifier/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/composer","download_url":"https://codeload.github.com/composer/metadata-minifier/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247968377,"owners_count":21025823,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-01T20:01:30.889Z","updated_at":"2025-04-09T03:14:34.670Z","avatar_url":"https://github.com/composer.png","language":"PHP","funding_links":[],"categories":["PHP"],"sub_categories":[],"readme":"composer/metadata-minifier\n==========================\n\nSmall utility library that handles metadata minification and expansion.\n\nThis is used by [Composer](https://github.com/composer/composer)'s 2.x repository metadata protocol.\n\n\nInstallation\n------------\n\nInstall the latest version with:\n\n```bash\ncomposer require composer/metadata-minifier\n```\n\n\nRequirements\n------------\n\n* PHP 5.3.2 is required but using the latest version of PHP is highly recommended.\n\n\nBasic usage\n-----------\n\n### `Composer\\MetadataMinifier\\MetadataMinifier`\n\n- `MetadataMinifier::expand()`: Expands an array of minified versions back to their original format\n- `MetadataMinifier::minify()`: Minifies an array of versions into a set of version diffs\n\nFor example to expand the dev versions (note the ~dev in the URL) of Monolog you would do:\n\n```php\n$packageName = 'monolog/monolog';\n$url = 'https://repo.packagist.org/p2/' . $packageName . '~dev.json';\n$json = json_decode(file_get_contents($url), true);\n$versions = \\Composer\\MetadataMinifier\\MetadataMinifier::expand($json['packages'][$packageName]);\n```\n\nLicense\n-------\n\ncomposer/metadata-minifier is licensed under the MIT License, see the LICENSE file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcomposer%2Fmetadata-minifier","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcomposer%2Fmetadata-minifier","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcomposer%2Fmetadata-minifier/lists"}