{"id":13523808,"url":"https://github.com/silpion/composer-checker","last_synced_at":"2025-04-01T01:33:34.473Z","repository":{"id":11701259,"uuid":"14216072","full_name":"silpion/composer-checker","owner":"silpion","description":null,"archived":true,"fork":false,"pushed_at":"2014-10-01T12:02:32.000Z","size":300,"stargazers_count":12,"open_issues_count":1,"forks_count":0,"subscribers_count":5,"default_branch":"master","last_synced_at":"2024-12-02T12:48:51.679Z","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/silpion.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-11-07T21:14:05.000Z","updated_at":"2024-10-09T08:45:41.000Z","dependencies_parsed_at":"2022-09-15T21:52:16.799Z","dependency_job_id":null,"html_url":"https://github.com/silpion/composer-checker","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/silpion%2Fcomposer-checker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/silpion%2Fcomposer-checker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/silpion%2Fcomposer-checker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/silpion%2Fcomposer-checker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/silpion","download_url":"https://codeload.github.com/silpion/composer-checker/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246567329,"owners_count":20798153,"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-01T06:01:03.895Z","updated_at":"2025-04-01T01:33:29.464Z","avatar_url":"https://github.com/silpion.png","language":"PHP","funding_links":[],"categories":["Dependency Management Extras","其他的依赖管理","其他的依赖管理 Dependency Management Extras"],"sub_categories":[],"readme":"[![Build Status](https://travis-ci.org/silpion/composer-checker.svg?branch=master)](https://travis-ci.org/silpion/composer-checker)\n\nComposer Checker\n======================\n\nA simple tool for various composer related checks and validations.\n\nUsage\n-----\n\n    $ php bin/composer-checker\n\n    Available commands:\n      help         Displays help for a command\n      list         Lists commands\n    check\n      check:dist   Matching the dist urls in a composer.lock file against some patterns.\n      check:src    Matching the src urls in a composer.lock file against some patterns.\n    remove\n      remove:dist   Removing dist urls from a composer.lock file.\n      remove:src    Removing src urls from a composer.lock file.\n\n\nCheck: Dist-Urls\n-------------------\n\nThis check is intended to validate the dist-urls in a composer.lock file.\nWhen using a Satis Mirror for your packages, it might break your ci/deployment when external dist-urls are used in your composer.lock file.\n\nSimply run this command to check against the url \"satis.example.com\":\n\n    $ php bin/composer-checker check:dist -p \"satis.example.com\" composer.lock\n     --- Invalid urls found ---\n    +-----------------+-----------------------------------------------------------------------------------------------+\n    | Package         | Dist-URL                                                                                      |\n    +-----------------+-----------------------------------------------------------------------------------------------+\n    | symfony/console | https://api.github.com/repos/symfony/Console/zipball/00848d3e13cf512e77c7498c2b3b0192f61f4b18 |\n    +-----------------+-----------------------------------------------------------------------------------------------+\n\nThe output gives a hint, which packages do not comply with the given url pattern, which is basically just a regex.\nA positive example with a more complex regex:\n\n    $ php bin/composer-checker check:dist -p \"^https://api.github.com/repos/(.+)/(.+)/zipball/([a-f0-9]+)$\" composer.lock\n    All urls valid.\n\nIt is also possible to enforce to use only \"https\" dist-urls with a pattern like this:\n\n    $ php bin/composer-checker check:dist -p \"^https://\" composer.lock\n\nAllowing empty or missing dist urls can be done with the `--allow-empty` switch.\n\n\nCheck: Source-Urls\n---------------------\n\nParallel to the dist urls, the source urls can be checked too.\n\n    $ php bin/composer-checker check:src -p \"git@git.example.com/foo.git\" composer.lock\n\n\nAllowing empty or missing source urls can be done with the `--allow-empty` switch.\n\n\nRemove: Dist-Urls\n-------------------\n\nThis command will remove distribution urls from a given `composer.lock` file.\nForcing composer to install all packages from \"source\".\n\nIt is possible to `--except` specific patterns like \"jquery.com\". These urls will _not_ be removed.\n\n    php bin/composer-checker remove:dist -e jquery.com composer.lock\n\n\nRemove: Source-Urls\n-------------------\n\nWorking the same as the `remove:dist` counterpart. Removing the \"source\" entries from a given `composer.lock` file.\n\n    php bin/composer-checker remove:src -e jquery.com composer.lock\n\nThis command can be very useful for automated deploying.\nBecause if a package mirror like Satis, holding \"dist\" copies, is not available, composer will silently fail back to using \"source\" packages creating a unnoticed dependency between production and the VCS.\nRemoving all the \"source\" entries from a composer.lock file, will force composer to only use the \"dist\" urls or stop with a failure.\n\n\nLICENSE\n-------\n\nThe license can be found here: [LICENSE](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsilpion%2Fcomposer-checker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsilpion%2Fcomposer-checker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsilpion%2Fcomposer-checker/lists"}