{"id":15743273,"url":"https://github.com/shivammathur/spc","last_synced_at":"2025-06-14T08:34:27.177Z","repository":{"id":57074596,"uuid":"313019267","full_name":"shivammathur/spc","owner":"shivammathur","description":"setup-php-cli (spc) is a command line utility to run setup-php.","archived":false,"fork":false,"pushed_at":"2025-04-17T10:44:48.000Z","size":38,"stargazers_count":5,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-05-13T01:38:26.551Z","etag":null,"topics":["cli","github-actions","php","setup-php"],"latest_commit_sha":null,"homepage":"https://packagist.org/packages/shivammathur/spc","language":"Shell","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/shivammathur.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":"shivammathur"}},"created_at":"2020-11-15T11:47:16.000Z","updated_at":"2025-04-17T10:44:51.000Z","dependencies_parsed_at":"2024-10-25T01:53:14.948Z","dependency_job_id":"6148a22c-930d-45d4-98da-7e6a9c1a0f38","html_url":"https://github.com/shivammathur/spc","commit_stats":{"total_commits":20,"total_committers":1,"mean_commits":20.0,"dds":0.0,"last_synced_commit":"a3f9d57ac3cd043f23941e69716d99d0fcdce51c"},"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/shivammathur/spc","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shivammathur%2Fspc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shivammathur%2Fspc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shivammathur%2Fspc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shivammathur%2Fspc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/shivammathur","download_url":"https://codeload.github.com/shivammathur/spc/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shivammathur%2Fspc/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259787199,"owners_count":22911145,"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":["cli","github-actions","php","setup-php"],"created_at":"2024-10-04T03:02:23.878Z","updated_at":"2025-06-14T08:34:27.162Z","avatar_url":"https://github.com/shivammathur.png","language":"Shell","funding_links":["https://github.com/sponsors/shivammathur"],"categories":[],"sub_categories":[],"readme":"# SPC\n\nsetup-php-cli (SPC) is a command line utility to run [setup-php](https://github.com/shivammathur/setup-php).\n\n## OS Support\n\n|Host OS/Virtual environment|PHP Supported|\n|--- |--- |\n|Ubuntu 24.04|`PHP 5.6` to `PHP 8.4`|\n|Ubuntu 22.04|`PHP 5.6` to `PHP 8.4`|\n|Windows with cygwin|`PHP 5.6` to `PHP 8.4`|\n|macOS Sequoia 15.x|`PHP 5.6` to `PHP 8.4`|\n|macOS Sonoma 14.x|`PHP 5.6` to `PHP 8.4`|\n|macOS Ventura 13.x|`PHP 5.6` to `PHP 8.4`|\n\n## Install\n\n- Using composer\n\n```bash\ncomposer global require shivammathur/spc\nsudo cp $(composer global config home)/vendor/bin/spc /usr/local/bin/spc\nsudo chmod a+x /usr/local/bin/spc\n```\n\n- Download from Releases\n\n```bash\n# Download\ncurl -o /tmp/spc -sL https://github.com/shivammathur/spc/releases/latest/download/spc\n\n# Verify\ncurl -o /tmp/spc.asc -sL https://github.com/shivammathur/spc/releases/latest/download/spc.asc\ncurl -o /tmp/key.asc -sL https://github.com/shivammathur.gpg\ngpg --import /tmp/key.asc\ngpg --verify /tmp/spc.asc /tmp/spc\n\n# Install\nsudo mv /tmp/spc /usr/local/bin/spc\nsudo chmod a+x /usr/local/bin/spc\n```\n\n## Options\n\n```bash\n-p \"[PHP Version]\", --php-version \"[PHP Version]\"    Specify PHP version (Required if PHP is not installed)\n-e \"[Extensions]\", --extensions \"[Extensions]\"       Specify extensions\n-b \"[INI File]\", --ini-file \"[INI Values]\"           Specify base ini file\n-i \"[INI Values]\", --ini-values \"[INI Values]\"       Specify ini values\n-c \"[Coverage]\", --coverage \"[Coverage]\"             Specify Coverage driver\n-t \"[Tools]\", --tools \"[Tools]\"                      Specify tools\n-f \"[Debug]\", --debug \"[Debug]\"                      Specify debug flag\n-f \"[Fail Fast]\", --fail-fast \"[Fail Fast]\"          Specify fail-fast flag\n-z \"[PHP TS/NTS]\", --phpts \"[PHPTS/NTS]\"             Specify phpts flag\n-u \"[Update]\", --update \"[Update]\"                   Specify update flag\n-r \"[TAG]\", --release \"[TAG]\"                        Specify release\n-v, --verbose                                        Specify verbose mode\n-V, --version                                        Show version of script\n-h, --help                                           Show help\n```\n\n## Examples\n\n- Install or switch to a particular PHP version. For example to install `PHP 7.4`.\n\n```bash\nspc -p \"7.4\"\n```\n\n- Install PHP extension, say `intl` and `xml` on `PHP 7.4`.\n\n```bash\nspc -e \"intl, xml\"\n```\n\n- Set the base php.ini file, say set it to `development`.\n\n```bash\nspc -b \"development\"\n```\n\n- Add any configuration to your php.ini, say set timezone to `UTC`.\n\n```bash\nspc -i \"date.timezone=UTC\"\n```\n\n- Set a coverage driver, say `PCOV`.\n\n```bash\nspc -c \"pcov\"\n```\n\n- Install a tool supported by `setup-php` globally.\n\n```bash\nspc -t \"phpunit\"\n```\n\n- Setup a debug build of PHP.\n\n```bash\nspc -p 8.1 -d \"true\"\n```\n\n- Fail if an extension, or a tool does not install.\n\n```bash\nspc -t \"random_tool\" -f \"true\"\n```\n\n- Update PHP to the latest patch version.\n\n```bash\nspc -u \"true\"\n```\n\n- Setup TS/NTS PHP on `Windows`. (Not supported currently)\n\n```bash\nspc -p \"7.4\" -z \"ts\"\n```\n\n- Use a particular tag/release of `setup-php`, say to use `v1`.\n\n```bash\nspc -r \"v1\"\n```\n\n- To run `spc` in the verbose mode, this will use `verbose` branch of `setup-php`.\n\n```bash\nspc -v\n```\n\n- To check options spc supports in command line.\n\n```bash\nspc -h\n```\n\n- To upgrade `spc` to latest version.\n\n```bash\nspc -U\n```\n\n- To check `spc` version.\n\n```bash\nspc -V\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshivammathur%2Fspc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshivammathur%2Fspc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshivammathur%2Fspc/lists"}