setup-php 2.16.0 → 2.17.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +154 -141
- package/lib/config.d.ts +3 -0
- package/lib/config.js +72 -0
- package/lib/config.js.map +1 -0
- package/lib/coverage.d.ts +5 -0
- package/lib/coverage.js +98 -0
- package/lib/coverage.js.map +1 -0
- package/lib/extensions.d.ts +4 -0
- package/lib/extensions.js +215 -0
- package/lib/extensions.js.map +1 -0
- package/lib/fetch.d.ts +1 -0
- package/lib/fetch.js +63 -0
- package/lib/fetch.js.map +1 -0
- package/lib/install.d.ts +2 -0
- package/lib/install.js +76 -0
- package/lib/install.js.map +1 -0
- package/lib/tools.d.ts +23 -0
- package/lib/tools.js +368 -0
- package/lib/tools.js.map +1 -0
- package/lib/utils.d.ts +21 -0
- package/lib/utils.js +262 -0
- package/lib/utils.js.map +1 -0
- package/package.json +18 -17
- package/src/config.ts +8 -8
- package/src/configs/brew_extensions +1 -0
- package/src/configs/composer.env +2 -0
- package/src/configs/ini/jit.ini +3 -0
- package/src/configs/ini/php.ini +2 -0
- package/src/configs/ini/xdebug.ini +1 -0
- package/src/configs/os_releases.csv +2 -0
- package/src/configs/php_packages +12 -0
- package/src/configs/tools.json +48 -26
- package/src/configs/tools_schema.json +11 -0
- package/src/coverage.ts +24 -49
- package/src/extensions.ts +23 -19
- package/src/fetch.ts +54 -0
- package/src/install.ts +27 -40
- package/src/scripts/darwin.sh +58 -30
- package/src/scripts/extensions/add_extensions.ps1 +194 -0
- package/src/scripts/extensions/add_extensions.sh +184 -0
- package/src/scripts/{ext → extensions}/blackfire.ps1 +0 -0
- package/src/scripts/{ext → extensions}/blackfire.sh +0 -0
- package/src/scripts/{ext → extensions}/couchbase.sh +0 -0
- package/src/scripts/{ext → extensions}/cubrid.sh +3 -3
- package/src/scripts/{ext → extensions}/extension_map.php +36 -13
- package/src/scripts/{ext → extensions}/firebird.ps1 +0 -0
- package/src/scripts/{ext → extensions}/firebird.sh +0 -0
- package/src/scripts/{ext → extensions}/gearman.sh +0 -0
- package/src/scripts/{ext → extensions}/geos.sh +0 -0
- package/src/scripts/{ext → extensions}/http.ps1 +0 -0
- package/src/scripts/{ext → extensions}/http.sh +4 -15
- package/src/scripts/{ext → extensions}/intl.sh +0 -0
- package/src/scripts/{ext → extensions}/ioncube.ps1 +2 -2
- package/src/scripts/{ext → extensions}/ioncube.sh +2 -2
- package/src/scripts/{ext → extensions}/oci.ps1 +39 -14
- package/src/scripts/{ext → extensions}/oci.sh +3 -3
- package/src/scripts/{ext → extensions}/patches/firebird.sh +0 -0
- package/src/scripts/{ext → extensions}/patches/geos.sh +0 -0
- package/src/scripts/{ext → extensions}/patches/http.sh +0 -0
- package/src/scripts/{ext → extensions}/patches/pdo_oci.sh +0 -0
- package/src/scripts/{ext → extensions}/patches/phpize.sh +0 -0
- package/src/scripts/{ext → extensions}/patches/protobuf.sh +0 -0
- package/src/scripts/{ext → extensions}/phalcon.ps1 +0 -0
- package/src/scripts/{ext → extensions}/phalcon.sh +4 -5
- package/src/scripts/{ext → extensions}/source.sh +23 -22
- package/src/scripts/extensions/sqlsrv.sh +15 -0
- package/src/scripts/linux.sh +63 -33
- package/src/scripts/tools/add_tools.ps1 +220 -10
- package/src/scripts/tools/add_tools.sh +164 -17
- package/src/scripts/tools/grpc_php_plugin.ps1 +4 -4
- package/src/scripts/tools/grpc_php_plugin.sh +3 -3
- package/src/scripts/tools/ppa.sh +12 -9
- package/src/scripts/tools/protoc.ps1 +2 -2
- package/src/scripts/tools/protoc.sh +2 -2
- package/src/scripts/tools/symfony.ps1 +14 -0
- package/src/scripts/tools/symfony.sh +13 -0
- package/src/scripts/unix.sh +186 -0
- package/src/scripts/win32.ps1 +126 -340
- package/src/tools.ts +56 -82
- package/src/utils.ts +57 -145
- package/src/scripts/common.sh +0 -366
package/README.md
CHANGED
|
@@ -11,7 +11,6 @@
|
|
|
11
11
|
<a href="https://codecov.io/gh/shivammathur/setup-php" title="Code coverage"><img alt="Codecov Code Coverage" src="https://img.shields.io/codecov/c/github/shivammathur/setup-php?logo=codecov"></a>
|
|
12
12
|
<a href="https://github.com/shivammathur/setup-php/blob/master/LICENSE" title="license"><img alt="LICENSE" src="https://img.shields.io/badge/license-MIT-428f7e.svg?logo=open%20source%20initiative&logoColor=white&labelColor=555555"></a>
|
|
13
13
|
<a href="#tada-php-support" title="PHP Versions Supported"><img alt="PHP Versions Supported" src="https://img.shields.io/badge/php-5.3%20to%208.2-777bb3.svg?logo=php&logoColor=white&labelColor=555555"></a>
|
|
14
|
-
<a href="https://beta.stepsecurity.io/npm/setup-php"><img alt="release verified" src="https://img.shields.io/endpoint?url=https://beta.api.stepsecurity.io/v1/npm/setup-php/badge?q=1"></a>
|
|
15
14
|
</p>
|
|
16
15
|
<p align="center">
|
|
17
16
|
<a href="https://reddit.com/r/setup_php" title="setup-php reddit"><img alt="setup-php reddit" src="https://img.shields.io/badge/reddit-join-FF5700?logo=reddit&logoColor=FF5700&labelColor=555555"></a>
|
|
@@ -19,14 +18,14 @@
|
|
|
19
18
|
<a href="https://status.setup-php.com" title="setup-php status"><img alt="setup-php status" src="https://img.shields.io/badge/status-subscribe-28A745?logo=statuspage&logoColor=28A745&labelColor=555555"></a>
|
|
20
19
|
</p>
|
|
21
20
|
|
|
22
|
-
Setup PHP with required extensions, php.ini configuration, code-coverage support and various tools like composer in [GitHub Actions](https://github.com/features/actions "GitHub Actions"). This action gives you a cross
|
|
21
|
+
Setup PHP with required extensions, php.ini configuration, code-coverage support and various tools like composer in [GitHub Actions](https://github.com/features/actions "GitHub Actions"). This action gives you a cross-platform interface to set up the PHP environment you need to test your application. Refer to [Usage](#memo-usage "How to use this") section and [examples](#examples "Examples of use") to see how to use this.
|
|
23
22
|
|
|
24
23
|
## Contents
|
|
25
24
|
|
|
26
25
|
- [OS/Platform Support](#cloud-osplatform-support)
|
|
27
26
|
- [GitHub-Hosted Runners](#github-hosted-runners)
|
|
28
27
|
- [Self-Hosted Runners](#self-hosted-runners)
|
|
29
|
-
- [PHP Support](#tada-php-support)
|
|
28
|
+
- [PHP Support](#tada-php-support)
|
|
30
29
|
- [PHP Extension Support](#heavy_plus_sign-php-extension-support)
|
|
31
30
|
- [Tools Support](#wrench-tools-support)
|
|
32
31
|
- [Coverage Support](#signal_strength-coverage-support)
|
|
@@ -38,11 +37,11 @@ Setup PHP with required extensions, php.ini configuration, code-coverage support
|
|
|
38
37
|
- [Outputs](#outputs)
|
|
39
38
|
- [Flags](#flags)
|
|
40
39
|
- [Basic Setup](#basic-setup)
|
|
41
|
-
- [Matrix Setup](#matrix-setup)
|
|
40
|
+
- [Matrix Setup](#matrix-setup)
|
|
42
41
|
- [Nightly Build Setup](#nightly-build-setup)
|
|
43
42
|
- [Thread Safe Setup](#thread-safe-setup)
|
|
44
43
|
- [Force Update Setup](#force-update-setup)
|
|
45
|
-
- [Verbose Setup](#verbose-setup)
|
|
44
|
+
- [Verbose Setup](#verbose-setup)
|
|
46
45
|
- [Multi-Arch Setup](#multi-arch-setup)
|
|
47
46
|
- [Self Hosted Setup](#self-hosted-setup)
|
|
48
47
|
- [Local Testing Setup](#local-testing-setup)
|
|
@@ -62,36 +61,37 @@ Setup PHP with required extensions, php.ini configuration, code-coverage support
|
|
|
62
61
|
|
|
63
62
|
## :cloud: OS/Platform Support
|
|
64
63
|
|
|
65
|
-
Both `GitHub-hosted` and `self-hosted` runners are
|
|
64
|
+
Both `GitHub-hosted` and `self-hosted` runners are supported by `setup-php` on the following OS/Platforms.
|
|
66
65
|
|
|
67
66
|
### GitHub-Hosted Runners
|
|
68
67
|
|
|
69
|
-
|Virtual environment|YAML workflow label|Pre-installed PHP|
|
|
70
|
-
|
|
71
|
-
|Ubuntu
|
|
72
|
-
|Ubuntu
|
|
73
|
-
|Windows Server
|
|
74
|
-
|Windows Server
|
|
75
|
-
|macOS
|
|
76
|
-
|macOS
|
|
68
|
+
| Virtual environment | YAML workflow label | Pre-installed PHP |
|
|
69
|
+
|-----------------------|------------------------------------|------------------------|
|
|
70
|
+
| Ubuntu 20.04 | `ubuntu-latest` or `ubuntu-20.04` | `PHP 7.4` to `PHP 8.1` |
|
|
71
|
+
| Ubuntu 18.04 | `ubuntu-18.04` | `PHP 7.1` to `PHP 8.1` |
|
|
72
|
+
| Windows Server 2022 | `windows-latest` or `windows-2022` | `PHP 8.1` |
|
|
73
|
+
| Windows Server 2019 | `windows-2019` | `PHP 8.1` |
|
|
74
|
+
| macOS Big Sur 11.x | `macos-11` | `PHP 8.1` |
|
|
75
|
+
| macOS Catalina 10.15 | `macos-latest` or `macos-10.15` | `PHP 8.1` |
|
|
77
76
|
|
|
78
77
|
### Self-Hosted Runners
|
|
79
78
|
|
|
80
|
-
|Host OS/Virtual environment|YAML workflow label|
|
|
81
|
-
|
|
82
|
-
|Ubuntu
|
|
83
|
-
|Ubuntu 20.04
|
|
84
|
-
|Ubuntu
|
|
85
|
-
|Debian
|
|
86
|
-
|Debian 10
|
|
87
|
-
|Debian
|
|
88
|
-
|Windows 7 and newer
|
|
89
|
-
|Windows Server 2012 R2 and newer
|
|
90
|
-
|macOS
|
|
91
|
-
|macOS Big Sur 11.x x86_64/arm64
|
|
79
|
+
| Host OS/Virtual environment | YAML workflow label |
|
|
80
|
+
|----------------------------------|----------------------------|
|
|
81
|
+
| Ubuntu 21.04 | `self-hosted` or `Linux` |
|
|
82
|
+
| Ubuntu 20.04 | `self-hosted` or `Linux` |
|
|
83
|
+
| Ubuntu 18.04 | `self-hosted` or `Linux` |
|
|
84
|
+
| Debian 11 | `self-hosted` or `Linux` |
|
|
85
|
+
| Debian 10 | `self-hosted` or `Linux` |
|
|
86
|
+
| Debian 9 | `self-hosted` or `Linux` |
|
|
87
|
+
| Windows 7 and newer | `self-hosted` or `Windows` |
|
|
88
|
+
| Windows Server 2012 R2 and newer | `self-hosted` or `Windows` |
|
|
89
|
+
| macOS Monterey 12.x x86_64/arm64 | `self-hosted` or `macOS` |
|
|
90
|
+
| macOS Big Sur 11.x x86_64/arm64 | `self-hosted` or `macOS` |
|
|
91
|
+
| macOS Catalina 10.15 | `self-hosted` or `macOS` |
|
|
92
92
|
|
|
93
93
|
- Refer to the [self-hosted setup](#self-hosted-setup) to use the action on self-hosted runners.
|
|
94
|
-
- Operating systems based on the above Ubuntu and Debian versions are also supported on
|
|
94
|
+
- Operating systems based on the above Ubuntu and Debian versions are also supported on best effort basis.
|
|
95
95
|
- If the requested PHP version is pre-installed, `setup-php` switches to it, otherwise it installs the PHP version.
|
|
96
96
|
|
|
97
97
|
## :tada: PHP Support
|
|
@@ -101,22 +101,22 @@ On all supported OS/Platforms the following PHP versions are supported as per th
|
|
|
101
101
|
- PHP 5.3 to PHP 8.2 on GitHub-hosted runners.
|
|
102
102
|
- PHP 5.6 to PHP 8.2 on self-hosted runners.
|
|
103
103
|
|
|
104
|
-
|PHP Version|Stability|Release Support|Runner Support|
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
**Notes:**
|
|
104
|
+
| PHP Version | Stability | Release Support | Runner Support |
|
|
105
|
+
|-------------|-----------|-----------------------|--------------------------------|
|
|
106
|
+
| `5.3` | `Stable` | `End of life` | `GitHub-hosted` |
|
|
107
|
+
| `5.4` | `Stable` | `End of life` | `GitHub-hosted` |
|
|
108
|
+
| `5.5` | `Stable` | `End of life` | `GitHub-hosted` |
|
|
109
|
+
| `5.6` | `Stable` | `End of life` | `GitHub-hosted`, `self-hosted` |
|
|
110
|
+
| `7.0` | `Stable` | `End of life` | `GitHub-hosted`, `self-hosted` |
|
|
111
|
+
| `7.1` | `Stable` | `End of life` | `GitHub-hosted`, `self-hosted` |
|
|
112
|
+
| `7.2` | `Stable` | `End of life` | `GitHub-hosted`, `self-hosted` |
|
|
113
|
+
| `7.3` | `Stable` | `End of life` | `GitHub-hosted`, `self-hosted` |
|
|
114
|
+
| `7.4` | `Stable` | `Security fixes only` | `GitHub-hosted`, `self-hosted` |
|
|
115
|
+
| `8.0` | `Stable` | `Active` | `GitHub-hosted`, `self-hosted` |
|
|
116
|
+
| `8.1` | `Stable` | `Active` | `GitHub-hosted`, `self-hosted` |
|
|
117
|
+
| `8.2` | `Nightly` | `In development` | `GitHub-hosted`, `self-hosted` |
|
|
118
|
+
|
|
119
|
+
**Notes:**
|
|
120
120
|
- Specifying `8.2` in `php-version` input installs a nightly build of `PHP 8.2.0-dev`. See [nightly build setup](#nightly-build-setup) for more information.
|
|
121
121
|
- To use JIT on `PHP 8.0` and above, refer to the [JIT configuration](#jit-configuration) section.
|
|
122
122
|
|
|
@@ -130,7 +130,7 @@ PHP extensions can be set up using the `extensions` input. It accepts a `string`
|
|
|
130
130
|
- name: Setup PHP with PECL extension
|
|
131
131
|
uses: shivammathur/setup-php@v2
|
|
132
132
|
with:
|
|
133
|
-
php-version: '8.
|
|
133
|
+
php-version: '8.1'
|
|
134
134
|
extensions: imagick, swoole
|
|
135
135
|
```
|
|
136
136
|
|
|
@@ -152,13 +152,13 @@ PHP extensions can be set up using the `extensions` input. It accepts a `string`
|
|
|
152
152
|
extensions: swoole-1.9.3
|
|
153
153
|
```
|
|
154
154
|
|
|
155
|
-
-
|
|
155
|
+
- Extensions with pre-release versions available on `PECL` can be set up by suffixing the extension's name with its state i.e `alpha`, `beta`, `devel` or `snapshot`.
|
|
156
156
|
|
|
157
157
|
```yaml
|
|
158
158
|
- name: Setup PHP with pre-release PECL extension
|
|
159
159
|
uses: shivammathur/setup-php@v2
|
|
160
160
|
with:
|
|
161
|
-
php-version: '8.
|
|
161
|
+
php-version: '8.1'
|
|
162
162
|
extensions: xdebug-beta
|
|
163
163
|
```
|
|
164
164
|
|
|
@@ -168,19 +168,19 @@ PHP extensions can be set up using the `extensions` input. It accepts a `string`
|
|
|
168
168
|
- name: Setup PHP and disable opcache
|
|
169
169
|
uses: shivammathur/setup-php@v2
|
|
170
170
|
with:
|
|
171
|
-
php-version: '8.
|
|
171
|
+
php-version: '8.1'
|
|
172
172
|
extensions: :opcache
|
|
173
173
|
```
|
|
174
174
|
|
|
175
175
|
- All shared extensions can be disabled by specifying `none`. When `none` is specified along with other extensions, it is hoisted to the start of the input. So, all the shared extensions will be disabled first, then rest of the extensions in the input will be processed.
|
|
176
|
-
|
|
177
|
-
**Note:** This disables all core and third-party shared extensions and thus, can break some tools which need them. So
|
|
176
|
+
|
|
177
|
+
**Note:** This disables all core and third-party shared extensions and thus, can break some tools which need them. Required extensions are enabled again when the tools are set up on a best-effort basis. So it is recommended to add the extensions required for your tools after `none` in the `extensions` input to avoid any issues.
|
|
178
178
|
|
|
179
179
|
```yaml
|
|
180
180
|
- name: Setup PHP without any shared extensions except mbstring
|
|
181
181
|
uses: shivammathur/setup-php@v2
|
|
182
182
|
with:
|
|
183
|
-
php-version: '8.
|
|
183
|
+
php-version: '8.1'
|
|
184
184
|
extensions: none, mbstring
|
|
185
185
|
```
|
|
186
186
|
|
|
@@ -190,8 +190,8 @@ PHP extensions can be set up using the `extensions` input. It accepts a `string`
|
|
|
190
190
|
- name: Setup PHP with intl
|
|
191
191
|
uses: shivammathur/setup-php@v2
|
|
192
192
|
with:
|
|
193
|
-
php-version: '8.
|
|
194
|
-
extensions: intl-
|
|
193
|
+
php-version: '8.1'
|
|
194
|
+
extensions: intl-70.1
|
|
195
195
|
```
|
|
196
196
|
|
|
197
197
|
- Extensions loaded by default after `setup-php` runs can be found on the [wiki](https://github.com/shivammathur/setup-php/wiki).
|
|
@@ -201,13 +201,13 @@ PHP extensions can be set up using the `extensions` input. It accepts a `string`
|
|
|
201
201
|
- `geos` on `Ubuntu` and `macOS`.
|
|
202
202
|
- `blackfire`, `couchbase`, `ioncube`, `oci8`, `pdo_firebird`, `pdo_oci`, `pecl_http`, `phalcon3` and `phalcon4` on all supported OS.
|
|
203
203
|
|
|
204
|
-
- By default, extensions which cannot be added or disabled gracefully leave an error message in the logs, the
|
|
204
|
+
- By default, extensions which cannot be added or disabled gracefully leave an error message in the logs, the execution is not interrupted. To change this behaviour you can set `fail-fast` flag to `true`.
|
|
205
205
|
|
|
206
206
|
```yaml
|
|
207
207
|
- name: Setup PHP with fail-fast
|
|
208
208
|
uses: shivammathur/setup-php@v2
|
|
209
209
|
with:
|
|
210
|
-
php-version: '8.
|
|
210
|
+
php-version: '8.1'
|
|
211
211
|
extensions: oci8
|
|
212
212
|
env:
|
|
213
213
|
fail-fast: true
|
|
@@ -217,13 +217,13 @@ PHP extensions can be set up using the `extensions` input. It accepts a `string`
|
|
|
217
217
|
|
|
218
218
|
These tools can be set up globally using the `tools` input. It accepts a string in csv-format.
|
|
219
219
|
|
|
220
|
-
[`behat`], [`blackfire`], [`blackfire-player`], [`codeception`], [`composer`], [`composer-normalize`], [`composer-prefetcher`], [`composer-require-checker`], [`composer-unused`], [`cs2pr`], [`deployer`], [`flex`], [`grpc_php_plugin`], [`infection`], [`parallel-lint`], [`pecl`], [`phan`], [`phing`], [`phinx`], [`phive`], [`php-config`], [`php-cs-fixer`], [`phpcbf`], [`phpcpd`], [`phpcs`], [`phpdoc`] or [`phpDocumentor`], [`phpize`], [`phplint`], [`phpmd`], [`phpspec`], [`phpstan`], [`phpunit`], [`phpunit-bridge`], [`phpunit-polyfills`], [`prestissimo`], [`protoc`], [`psalm`], [`symfony`] or [`symfony-cli`], [`vapor`] or [`vapor-cli`], [`wp`] or [`wp-cli`]
|
|
220
|
+
[`behat`], [`blackfire`], [`blackfire-player`], [`churn`], [`codeception`], [`composer`], [`composer-normalize`], [`composer-prefetcher`], [`composer-require-checker`], [`composer-unused`], [`cs2pr`], [`deployer`], [`flex`], [`grpc_php_plugin`], [`infection`], [`parallel-lint`], [`pecl`], [`phan`], [`phing`], [`phinx`], [`phive`], [`php-config`], [`php-cs-fixer`], [`phpcbf`], [`phpcpd`], [`phpcs`], [`phpdoc`] or [`phpDocumentor`], [`phpize`], [`phplint`], [`phpmd`], [`phpspec`], [`phpstan`], [`phpunit`], [`phpunit-bridge`], [`phpunit-polyfills`], [`prestissimo`], [`protoc`], [`psalm`], [`symfony`] or [`symfony-cli`], [`vapor`] or [`vapor-cli`], [`wp`] or [`wp-cli`]
|
|
221
221
|
|
|
222
222
|
```yaml
|
|
223
223
|
- name: Setup PHP with tools
|
|
224
224
|
uses: shivammathur/setup-php@v2
|
|
225
225
|
with:
|
|
226
|
-
php-version: '8.
|
|
226
|
+
php-version: '8.1'
|
|
227
227
|
tools: php-cs-fixer, phpunit
|
|
228
228
|
```
|
|
229
229
|
|
|
@@ -233,7 +233,7 @@ These tools can be set up globally using the `tools` input. It accepts a string
|
|
|
233
233
|
- name: Setup PHP with tools
|
|
234
234
|
uses: shivammathur/setup-php@v2
|
|
235
235
|
with:
|
|
236
|
-
php-version: '8.
|
|
236
|
+
php-version: '8.1'
|
|
237
237
|
tools: vimeo/psalm
|
|
238
238
|
```
|
|
239
239
|
|
|
@@ -252,8 +252,8 @@ These tools can be set up globally using the `tools` input. It accepts a string
|
|
|
252
252
|
- name: Setup PHP with tools
|
|
253
253
|
uses: shivammathur/setup-php@v2
|
|
254
254
|
with:
|
|
255
|
-
php-version: '8.
|
|
256
|
-
tools: php-cs-fixer:3, phpunit:
|
|
255
|
+
php-version: '8.1'
|
|
256
|
+
tools: php-cs-fixer:3.5, phpunit:9.5
|
|
257
257
|
env:
|
|
258
258
|
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
259
259
|
```
|
|
@@ -264,7 +264,7 @@ These tools can be set up globally using the `tools` input. It accepts a string
|
|
|
264
264
|
- name: Setup PHP with composer v2
|
|
265
265
|
uses: shivammathur/setup-php@v2
|
|
266
266
|
with:
|
|
267
|
-
php-version: '8.
|
|
267
|
+
php-version: '8.1'
|
|
268
268
|
tools: composer:v2
|
|
269
269
|
```
|
|
270
270
|
|
|
@@ -274,32 +274,32 @@ These tools can be set up globally using the `tools` input. It accepts a string
|
|
|
274
274
|
- name: Setup PHP without composer
|
|
275
275
|
uses: shivammathur/setup-php@v2
|
|
276
276
|
with:
|
|
277
|
-
php-version: '8.
|
|
277
|
+
php-version: '8.1'
|
|
278
278
|
tools: none
|
|
279
279
|
```
|
|
280
280
|
|
|
281
|
-
-
|
|
281
|
+
- Tools `pear`, `pecl`, `phpize` and `php-config` are set up by default for all supported PHP versions on Linux and macOS.
|
|
282
282
|
|
|
283
283
|
- The latest version of `blackfire` cli is set up when `blackfire` is specified in tools input. Please refer to the [official documentation](https://blackfire.io/docs/integrations/ci/github-actions "Blackfire.io documentation for GitHub Actions") for using `blackfire` with GitHub Actions.
|
|
284
284
|
|
|
285
285
|
- Tools `prestissimo` and `composer-prefetcher` will be skipped unless `composer:v1` is also specified in tools input. It is recommended to drop `prestissimo` and use `composer v2`.
|
|
286
286
|
|
|
287
|
-
- By default, tools which cannot be set up gracefully leave an error message in the logs, the
|
|
287
|
+
- By default, expect `composer` tools which cannot be set up gracefully leave an error message in the logs, the execution is not interrupted. To change this behaviour you can set `fail-fast` flag to `true`.
|
|
288
288
|
|
|
289
289
|
```yaml
|
|
290
290
|
- name: Setup PHP with fail-fast
|
|
291
291
|
uses: shivammathur/setup-php@v2
|
|
292
292
|
with:
|
|
293
|
-
php-version: '8.
|
|
293
|
+
php-version: '8.1'
|
|
294
294
|
tools: deployer
|
|
295
295
|
env:
|
|
296
296
|
fail-fast: true
|
|
297
297
|
```
|
|
298
298
|
|
|
299
299
|
**Notes**
|
|
300
|
-
- Input `tools` is useful to set up tools which
|
|
301
|
-
- If you do not want to use all your dev-dependencies in
|
|
302
|
-
-
|
|
300
|
+
- Input `tools` is useful to set up tools which are only used in CI workflows, thus keeping your `composer.json` tidy.
|
|
301
|
+
- If you do not want to use all your dev-dependencies in workflow, you can run composer with `--no-dev` and install required tools using `tools` input to speed up your workflow.
|
|
302
|
+
- By default, `COMPOSER_NO_INTERACTION` is set to `1` and `COMPOSER_PROCESS_TIMEOUT` is set to `0`. In effect, this means that Composer commands in your scripts do not need to specify `--no-interaction`.
|
|
303
303
|
|
|
304
304
|
## :signal_strength: Coverage Support
|
|
305
305
|
|
|
@@ -312,11 +312,11 @@ Runs on all [PHP versions supported](#tada-php-support "List of PHP versions sup
|
|
|
312
312
|
- name: Setup PHP with Xdebug
|
|
313
313
|
uses: shivammathur/setup-php@v2
|
|
314
314
|
with:
|
|
315
|
-
php-version: '8.
|
|
315
|
+
php-version: '8.1'
|
|
316
316
|
coverage: xdebug
|
|
317
317
|
```
|
|
318
318
|
|
|
319
|
-
-
|
|
319
|
+
- When you specify `coverage: xdebug`, the latest version of Xdebug compatible with the PHP version is set up by default.
|
|
320
320
|
- If you need Xdebug 2.x on PHP 7.2, 7.3 or 7.4, you can specify `coverage: xdebug2`.
|
|
321
321
|
|
|
322
322
|
```yaml
|
|
@@ -327,6 +327,8 @@ Runs on all [PHP versions supported](#tada-php-support "List of PHP versions sup
|
|
|
327
327
|
coverage: xdebug2
|
|
328
328
|
```
|
|
329
329
|
|
|
330
|
+
**Note**: Xdebug is enabled by default on Ubuntu GitHub Actions images, so if you are not using it in your workflow it is recommended to disable it as that will have a positive impact on your PHP performance. Please refer to the [disable coverage](#disable-coverage) section for details.
|
|
331
|
+
|
|
330
332
|
### PCOV
|
|
331
333
|
|
|
332
334
|
Specify `coverage: pcov` to use `PCOV` and disable `Xdebug`.
|
|
@@ -338,7 +340,7 @@ Runs on PHP 7.1 and newer PHP versions.
|
|
|
338
340
|
- name: Setup PHP with PCOV
|
|
339
341
|
uses: shivammathur/setup-php@v2
|
|
340
342
|
with:
|
|
341
|
-
php-version: '8.
|
|
343
|
+
php-version: '8.1'
|
|
342
344
|
ini-values: pcov.directory=api #optional, see above for usage.
|
|
343
345
|
coverage: pcov
|
|
344
346
|
```
|
|
@@ -360,7 +362,6 @@ Specify `coverage: none` to disable both `Xdebug` and `PCOV`.
|
|
|
360
362
|
Disable coverage for these reasons:
|
|
361
363
|
|
|
362
364
|
- You are not generating coverage reports while testing.
|
|
363
|
-
- It will disable `Xdebug`, which will have a positive impact on PHP performance.
|
|
364
365
|
- You are using `phpdbg` for running your tests.
|
|
365
366
|
- You are profiling your code using `blackfire`.
|
|
366
367
|
- You are using PHP in JIT mode. Please refer to [JIT configuration](#jit-configuration) section for more details.
|
|
@@ -369,7 +370,7 @@ Disable coverage for these reasons:
|
|
|
369
370
|
- name: Setup PHP with no coverage driver
|
|
370
371
|
uses: shivammathur/setup-php@v2
|
|
371
372
|
with:
|
|
372
|
-
php-version: '8.
|
|
373
|
+
php-version: '8.1'
|
|
373
374
|
coverage: none
|
|
374
375
|
```
|
|
375
376
|
|
|
@@ -396,6 +397,12 @@ Disable coverage for these reasons:
|
|
|
396
397
|
- Shared extensions prefixed with `:` are disabled.
|
|
397
398
|
- See [PHP extension support](#heavy_plus_sign-php-extension-support) for more info.
|
|
398
399
|
|
|
400
|
+
#### `ini-file` (optional)
|
|
401
|
+
|
|
402
|
+
- Specify the base `php.ini` file.
|
|
403
|
+
- Accepts `production`, `development` or `none`.
|
|
404
|
+
- By default, production `php.ini` file is used.
|
|
405
|
+
|
|
399
406
|
#### `ini-values` (optional)
|
|
400
407
|
|
|
401
408
|
- Specify the values you want to add to `php.ini`.
|
|
@@ -418,7 +425,7 @@ Disable coverage for these reasons:
|
|
|
418
425
|
|
|
419
426
|
#### `php-version`
|
|
420
427
|
|
|
421
|
-
|
|
428
|
+
On GitHub Actions you can assign the `setup-php` step an `id`, you can use the same to get the outputs in a later step.
|
|
422
429
|
|
|
423
430
|
- Provides the PHP version in semver format.
|
|
424
431
|
|
|
@@ -427,7 +434,7 @@ To use outputs, give the `setup-php` step an `id`, you can use the same to get t
|
|
|
427
434
|
id: setup-php
|
|
428
435
|
uses: shivammathur/setup-php@v2
|
|
429
436
|
with:
|
|
430
|
-
php-version: '8.
|
|
437
|
+
php-version: '8.1'
|
|
431
438
|
|
|
432
439
|
- name: Print PHP version
|
|
433
440
|
run: echo ${{ steps.setup-php.outputs.php-version }}
|
|
@@ -462,14 +469,14 @@ See below for more info.
|
|
|
462
469
|
|
|
463
470
|
### Basic Setup
|
|
464
471
|
|
|
465
|
-
>
|
|
472
|
+
> Set up a particular PHP version.
|
|
466
473
|
|
|
467
474
|
```yaml
|
|
468
475
|
steps:
|
|
469
476
|
- name: Setup PHP
|
|
470
477
|
uses: shivammathur/setup-php@v2
|
|
471
478
|
with:
|
|
472
|
-
php-version: '8.
|
|
479
|
+
php-version: '8.1'
|
|
473
480
|
extensions: mbstring, intl
|
|
474
481
|
ini-values: post_max_size=256M, max_execution_time=180
|
|
475
482
|
coverage: xdebug
|
|
@@ -478,7 +485,7 @@ steps:
|
|
|
478
485
|
|
|
479
486
|
### Matrix Setup
|
|
480
487
|
|
|
481
|
-
>
|
|
488
|
+
> Set up multiple PHP versions on multiple operating systems.
|
|
482
489
|
|
|
483
490
|
```yaml
|
|
484
491
|
jobs:
|
|
@@ -487,7 +494,7 @@ jobs:
|
|
|
487
494
|
strategy:
|
|
488
495
|
matrix:
|
|
489
496
|
operating-system: ['ubuntu-latest', 'windows-latest', 'macos-latest']
|
|
490
|
-
php-versions: ['7.
|
|
497
|
+
php-versions: ['7.4', '8.0', '8.1']
|
|
491
498
|
phpunit-versions: ['latest']
|
|
492
499
|
include:
|
|
493
500
|
- operating-system: 'ubuntu-latest'
|
|
@@ -506,9 +513,9 @@ jobs:
|
|
|
506
513
|
|
|
507
514
|
### Nightly Build Setup
|
|
508
515
|
|
|
509
|
-
>
|
|
516
|
+
> Set up a nightly build of `PHP 8.2`.
|
|
510
517
|
|
|
511
|
-
- This version is currently in development.
|
|
518
|
+
- This PHP version is currently in active development and might contain bugs and breaking changes.
|
|
512
519
|
- Some user space extensions might not support this version currently.
|
|
513
520
|
|
|
514
521
|
```yaml
|
|
@@ -525,7 +532,7 @@ steps:
|
|
|
525
532
|
|
|
526
533
|
### Thread Safe Setup
|
|
527
534
|
|
|
528
|
-
>
|
|
535
|
+
> Set up `TS` or `NTS` PHP on `Windows`.
|
|
529
536
|
|
|
530
537
|
- `NTS` versions are set up by default.
|
|
531
538
|
- On `Ubuntu` and `macOS` only `NTS` versions are supported.
|
|
@@ -540,7 +547,7 @@ jobs:
|
|
|
540
547
|
- name: Setup PHP
|
|
541
548
|
uses: shivammathur/setup-php@v2
|
|
542
549
|
with:
|
|
543
|
-
php-version: '8.
|
|
550
|
+
php-version: '8.1'
|
|
544
551
|
env:
|
|
545
552
|
phpts: ts # specify ts or nts
|
|
546
553
|
```
|
|
@@ -549,14 +556,14 @@ jobs:
|
|
|
549
556
|
|
|
550
557
|
> Update to the latest patch of PHP versions.
|
|
551
558
|
|
|
552
|
-
- Pre-installed PHP versions
|
|
559
|
+
- Pre-installed PHP versions are not updated to their latest patch release by default.
|
|
553
560
|
- You can specify the `update` environment variable to `true` for updating to the latest release.
|
|
554
561
|
|
|
555
562
|
```yaml
|
|
556
563
|
- name: Setup PHP with latest versions
|
|
557
564
|
uses: shivammathur/setup-php@v2
|
|
558
565
|
with:
|
|
559
|
-
php-version: '8.
|
|
566
|
+
php-version: '8.1'
|
|
560
567
|
env:
|
|
561
568
|
update: true # specify true or false
|
|
562
569
|
```
|
|
@@ -571,15 +578,15 @@ To debug any issues, you can use the `verbose` tag instead of `v2`.
|
|
|
571
578
|
- name: Setup PHP with logs
|
|
572
579
|
uses: shivammathur/setup-php@verbose
|
|
573
580
|
with:
|
|
574
|
-
php-version: '8.
|
|
581
|
+
php-version: '8.1'
|
|
575
582
|
```
|
|
576
583
|
|
|
577
584
|
### Multi-Arch Setup
|
|
578
585
|
|
|
579
|
-
>
|
|
586
|
+
> Set up PHP on multiple architecture on Ubuntu GitHub Runners.
|
|
580
587
|
|
|
581
|
-
- `PHP 5.6` to `PHP 8.
|
|
582
|
-
- For this, you can use `shivammathur/node` images as containers. These have compatible `Nodejs` installed for
|
|
588
|
+
- `PHP 5.6` to `PHP 8.1` are supported by `setup-php` on multiple architecture on `Ubuntu`.
|
|
589
|
+
- For this, you can use `shivammathur/node` images as containers. These have compatible `Nodejs` installed for `setup-php`.
|
|
583
590
|
- Currently, for `ARM` based setup, you will need [self-hosted runners](#self-hosted-setup).
|
|
584
591
|
|
|
585
592
|
```yaml
|
|
@@ -594,12 +601,12 @@ jobs:
|
|
|
594
601
|
- name: Install PHP
|
|
595
602
|
uses: shivammathur/setup-php@v2
|
|
596
603
|
with:
|
|
597
|
-
php-version: '8.
|
|
604
|
+
php-version: '8.1'
|
|
598
605
|
```
|
|
599
606
|
|
|
600
607
|
### Self Hosted Setup
|
|
601
608
|
|
|
602
|
-
>
|
|
609
|
+
> Set up PHP on a self-hosted runner.
|
|
603
610
|
|
|
604
611
|
- To set up a containerised self-hosted runner, refer to the following guides as per your base operating system.
|
|
605
612
|
- [Linux](https://github.com/shivammathur/setup-php/wiki/Dockerized-self-hosted-runner-on-Linux)
|
|
@@ -608,7 +615,7 @@ jobs:
|
|
|
608
615
|
- To set up the runner directly on the host OS or in a virtual machine, follow this [requirements guide](https://github.com/shivammathur/setup-php/wiki/Requirements-for-self-hosted-runners "Requirements guide for self-hosted runner to run setup-php") before setting up the self-hosted runner.
|
|
609
616
|
- If your workflow uses [service containers](https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idservices "GitHub Actions Services"), then set up the runner on a Linux host or in a Linux virtual machine. GitHub Actions does not support nested virtualization on Linux, so services will not work in a dockerized container.
|
|
610
617
|
|
|
611
|
-
|
|
618
|
+
It is recommended to specify the environment variable `runner` with the value `self-hosted` for self-hosted environments.
|
|
612
619
|
|
|
613
620
|
```yaml
|
|
614
621
|
jobs:
|
|
@@ -624,7 +631,7 @@ jobs:
|
|
|
624
631
|
with:
|
|
625
632
|
php-version: ${{ matrix.php-versions }}
|
|
626
633
|
env:
|
|
627
|
-
runner: self-hosted
|
|
634
|
+
runner: self-hosted
|
|
628
635
|
```
|
|
629
636
|
|
|
630
637
|
**Notes**
|
|
@@ -644,7 +651,7 @@ jobs:
|
|
|
644
651
|
- name: Setup PHP
|
|
645
652
|
uses: shivammathur/setup-php@v2
|
|
646
653
|
with:
|
|
647
|
-
php-version: '8.
|
|
654
|
+
php-version: '8.1'
|
|
648
655
|
```
|
|
649
656
|
|
|
650
657
|
Run the workflow locally with `act` using [`shivammathur/node`](https://github.com/shivammathur/node-docker "Docker image to run setup-php") docker images.
|
|
@@ -677,7 +684,7 @@ For example to enable JIT in `tracing` mode with buffer size of `64 MB`.
|
|
|
677
684
|
- name: Setup PHP with JIT in tracing mode
|
|
678
685
|
uses: shivammathur/setup-php@v2
|
|
679
686
|
with:
|
|
680
|
-
php-version: '8.
|
|
687
|
+
php-version: '8.1'
|
|
681
688
|
coverage: none
|
|
682
689
|
ini-values: opcache.enable_cli=1, opcache.jit=tracing, opcache.jit_buffer_size=64M
|
|
683
690
|
```
|
|
@@ -716,7 +723,7 @@ key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}
|
|
|
716
723
|
|
|
717
724
|
- If you support a range of `composer` dependencies and use `prefer-lowest` and `prefer-stable` options, you can store them in your matrix and add them to the keys.
|
|
718
725
|
```yaml
|
|
719
|
-
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
|
|
726
|
+
key: ${{ runner.os }}-composer-${{ matrix.prefer }}-${{ hashFiles('**/composer.lock') }}
|
|
720
727
|
restore-keys: ${{ runner.os }}-composer-${{ matrix.prefer }}-
|
|
721
728
|
```
|
|
722
729
|
|
|
@@ -728,7 +735,7 @@ If you have a number of workflows which set up multiple tools or have many compo
|
|
|
728
735
|
- name: Setup PHP
|
|
729
736
|
uses: shivammathur/setup-php@v2
|
|
730
737
|
with:
|
|
731
|
-
php-version: '8.
|
|
738
|
+
php-version: '8.1'
|
|
732
739
|
env:
|
|
733
740
|
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
734
741
|
```
|
|
@@ -743,7 +750,7 @@ Put the code in the run property of a step and specify the shell as `php {0}`.
|
|
|
743
750
|
- name: Setup PHP
|
|
744
751
|
uses: shivammathur/setup-php@v2
|
|
745
752
|
with:
|
|
746
|
-
php-version: '8.
|
|
753
|
+
php-version: '8.1'
|
|
747
754
|
|
|
748
755
|
- name: Run PHP code
|
|
749
756
|
shell: php {0}
|
|
@@ -783,7 +790,7 @@ PHPStan supports error reporting in GitHub Actions, so it does not require probl
|
|
|
783
790
|
- name: Setup PHP
|
|
784
791
|
uses: shivammathur/setup-php@v2
|
|
785
792
|
with:
|
|
786
|
-
php-version: '8.
|
|
793
|
+
php-version: '8.1'
|
|
787
794
|
tools: phpstan
|
|
788
795
|
|
|
789
796
|
- name: Run PHPStan
|
|
@@ -798,7 +805,7 @@ Psalm supports error reporting in GitHub Actions with an output format `github`.
|
|
|
798
805
|
- name: Setup PHP
|
|
799
806
|
uses: shivammathur/setup-php@v2
|
|
800
807
|
with:
|
|
801
|
-
php-version: '8.
|
|
808
|
+
php-version: '8.1'
|
|
802
809
|
tools: psalm
|
|
803
810
|
|
|
804
811
|
- name: Run Psalm
|
|
@@ -816,7 +823,7 @@ For examples refer to [cs2pr documentation](https://github.com/staabm/annotate-p
|
|
|
816
823
|
- name: Setup PHP
|
|
817
824
|
uses: shivammathur/setup-php@v2
|
|
818
825
|
with:
|
|
819
|
-
php-version: '8.
|
|
826
|
+
php-version: '8.1'
|
|
820
827
|
tools: cs2pr, phpcs
|
|
821
828
|
|
|
822
829
|
- name: Run phpcs
|
|
@@ -827,37 +834,38 @@ For examples refer to [cs2pr documentation](https://github.com/staabm/annotate-p
|
|
|
827
834
|
|
|
828
835
|
Examples of using `setup-php` with various PHP Frameworks and Packages.
|
|
829
836
|
|
|
830
|
-
|Framework/Package|Runs on|Workflow|
|
|
831
|
-
|
|
832
|
-
|Blackfire
|
|
833
|
-
|Blackfire Player
|
|
834
|
-
|CakePHP with `MySQL` and `Redis
|
|
835
|
-
|CakePHP with `PostgreSQL` and `Redis
|
|
836
|
-
|CakePHP without services
|
|
837
|
-
|CodeIgniter
|
|
838
|
-
|
|
|
839
|
-
|Laravel with `
|
|
840
|
-
|Laravel
|
|
841
|
-
|
|
|
842
|
-
|Lumen with `
|
|
843
|
-
|Lumen
|
|
844
|
-
|
|
|
845
|
-
|Phalcon with `
|
|
846
|
-
|
|
|
847
|
-
|Roots/
|
|
848
|
-
|
|
|
849
|
-
|
|
|
850
|
-
|Symfony with `
|
|
851
|
-
|Symfony
|
|
852
|
-
|
|
|
853
|
-
|Yii2 Starter Kit with `
|
|
854
|
-
|
|
|
837
|
+
| Framework/Package | Runs on | Workflow |
|
|
838
|
+
|----------------------------------------|---------------------------------|---------------------------------------------------------------------------------------------------------------|
|
|
839
|
+
| Blackfire | `macOS`, `ubuntu` and `windows` | [blackfire.yml](./examples/blackfire.yml "GitHub Action using Blackfire") |
|
|
840
|
+
| Blackfire Player | `macOS`, `ubuntu` and `windows` | [blackfire-player.yml](./examples/blackfire-player.yml "GitHub Action using Blackfire Player") |
|
|
841
|
+
| CakePHP with `MySQL` and `Redis` | `ubuntu` | [cakephp-mysql.yml](./examples/cakephp-mysql.yml "GitHub Action for CakePHP with MySQL and Redis") |
|
|
842
|
+
| CakePHP with `PostgreSQL` and `Redis` | `ubuntu` | [cakephp-postgres.yml](./examples/cakephp-postgres.yml "GitHub Action for CakePHP with Postgres and Redis") |
|
|
843
|
+
| CakePHP without services | `macOS`, `ubuntu` and `windows` | [cakephp.yml](./examples/cakephp.yml "GitHub Action for CakePHP without services") |
|
|
844
|
+
| CodeIgniter | `macOS`, `ubuntu` and `windows` | [codeigniter.yml](./examples/codeigniter.yml "GitHub Action for CodeIgniter") |
|
|
845
|
+
| Laminas MVC | `macOS`, `ubuntu` and `windows` | [laminas-mvc.yml](./examples/laminas-mvc.yml "GitHub Action for Laminas Framework MVC Projects") |
|
|
846
|
+
| Laravel with `MySQL` and `Redis` | `ubuntu` | [laravel-mysql.yml](./examples/laravel-mysql.yml "GitHub Action for Laravel with MySQL and Redis") |
|
|
847
|
+
| Laravel with `PostgreSQL` and `Redis` | `ubuntu` | [laravel-postgres.yml](./examples/laravel-postgres.yml "GitHub Action for Laravel with PostgreSQL and Redis") |
|
|
848
|
+
| Laravel without services | `macOS`, `ubuntu` and `windows` | [laravel.yml](./examples/laravel.yml "GitHub Action for Laravel without services") |
|
|
849
|
+
| Lumen with `MySQL` and `Redis` | `ubuntu` | [lumen-mysql.yml](./examples/lumen-mysql.yml "GitHub Action for Lumen with MySQL and Redis") |
|
|
850
|
+
| Lumen with `PostgreSQL` and `Redis` | `ubuntu` | [lumen-postgres.yml](./examples/lumen-postgres.yml "GitHub Action for Lumen with PostgreSQL and Redis") |
|
|
851
|
+
| Lumen without services | `macOS`, `ubuntu` and `windows` | [lumen.yml](./examples/lumen.yml "GitHub Action for Lumen without services") |
|
|
852
|
+
| Phalcon with `MySQL` | `ubuntu` | [phalcon-mysql.yml](./examples/phalcon-mysql.yml "GitHub Action for Phalcon with MySQL") |
|
|
853
|
+
| Phalcon with `PostgreSQL` | `ubuntu` | [phalcon-postgres.yml](./examples/phalcon-postgres.yml "GitHub Action for Phalcon with PostgreSQL") |
|
|
854
|
+
| Roots/bedrock | `ubuntu` | [bedrock.yml](./examples/bedrock.yml "GitHub Action for Wordpress Development using @roots/bedrock") |
|
|
855
|
+
| Roots/sage | `ubuntu` | [sage.yml](./examples/sage.yml "GitHub Action for Wordpress Development using @roots/sage") |
|
|
856
|
+
| Slim Framework | `macOS`, `ubuntu` and `windows` | [slim-framework.yml](./examples/slim-framework.yml "GitHub Action for Slim Framework") |
|
|
857
|
+
| Symfony with `MySQL` | `ubuntu` | [symfony-mysql.yml](./examples/symfony-mysql.yml "GitHub Action for Symfony with MySQL") |
|
|
858
|
+
| Symfony with `PostgreSQL` | `ubuntu` | [symfony-postgres.yml](./examples/symfony-postgres.yml "GitHub Action for Symfony with PostgreSQL") |
|
|
859
|
+
| Symfony without services | `macOS`, `ubuntu` and `windows` | [symfony.yml](./examples/symfony.yml "GitHub Action for Symfony without services") |
|
|
860
|
+
| Yii2 Starter Kit with `MySQL` | `ubuntu` | [yii2-mysql.yml](./examples/yii2-mysql.yml "GitHub Action for Yii2 Starter Kit with MySQL") |
|
|
861
|
+
| Yii2 Starter Kit with `PostgreSQL` | `ubuntu` | [yii2-postgres.yml](./examples/yii2-postgres.yml "GitHub Action for Yii2 Starter Kit with PostgreSQL") |
|
|
855
862
|
|
|
856
863
|
## :bookmark: Versioning
|
|
857
864
|
|
|
858
|
-
- Use the `v2` tag as `setup-php` version. It is a rolling tag and is synced with the latest minor and patch releases. With `v2` you automatically get the bug fixes, security patches, new features and support for latest PHP releases.
|
|
865
|
+
- Use the `v2` tag as `setup-php` version. It is a rolling tag and is synced with the latest minor and patch releases. With `v2` you automatically get the bug fixes, security patches, new features and support for latest PHP releases.
|
|
859
866
|
- Semantic release versions can also be used. It is recommended to [use dependabot](https://docs.github.com/en/github/administering-a-repository/keeping-your-actions-up-to-date-with-github-dependabot "Setup Dependabot with GitHub Actions") with semantic versioning to keep the actions in your workflows up to date.
|
|
860
|
-
- Commit SHA can also be used, but are not recommended. They have to be updated with every release manually, without which you will not get any bug fixes, security patches or new features.
|
|
867
|
+
- Commit SHA can also be used, but are not recommended. They have to be updated with every release manually, without which you will not get any bug fixes, security patches or new features.
|
|
868
|
+
- For debugging any issues `verbose` tag can be used temporarily. It outputs all the logs and is also synced with the latest releases.
|
|
861
869
|
- It is highly discouraged to use the `master` branch as version, it might break your workflow after major releases as they have breaking changes.
|
|
862
870
|
- If you are using the `v1` tag or a `1.x.y` version, you should [switch to v2](https://github.com/shivammathur/setup-php/wiki/Switch-to-v2 "Guide for switching from setup-php v1 to v2") as `v1` only gets critical bug fixes. Maintenance support for `v1` will be dropped with the last `PHP 8.0` release.
|
|
863
871
|
|
|
@@ -884,25 +892,29 @@ Examples of using `setup-php` with various PHP Frameworks and Packages.
|
|
|
884
892
|
|
|
885
893
|
## :sparkling_heart: Support This Project
|
|
886
894
|
|
|
887
|
-
- Please star the project and share it. If you blog, please share your experience of using
|
|
888
|
-
- Please sponsor setup-php using [GitHub sponsors](https://github.com/sponsors/shivammathur).
|
|
895
|
+
- Please star the project and share it. If you blog, please share your experience of using `setup-php`.
|
|
889
896
|
- Please [reach out](mailto:contact@setup-php.com) if you have any questions about sponsoring setup-php.
|
|
890
897
|
|
|
891
|
-
|
|
898
|
+
Many users and organisations support setup-php via [GitHub Sponsors](https://github.com/sponsors/shivammathur).
|
|
892
899
|
|
|
893
|
-
|
|
900
|
+
<a href="https://github.com/sponsors/shivammathur"><img src="https://setup-php.com/sponsors.svg?" alt="Sponsor shivammathur"></a>
|
|
894
901
|
|
|
895
|
-
|
|
896
|
-
<a href="https://setup-php.com/sponsors-corp/?">
|
|
897
|
-
<img src="https://setup-php.com/sponsors-corp/?" alt="Corporate sponsors of setup-php and related projects" width="100%">
|
|
898
|
-
</a>
|
|
899
|
-
</p>
|
|
900
|
-
|
|
901
|
-
### Individual Sponsors
|
|
902
|
+
These companies generously provide setup-php their products and services to aid in the development of this project.
|
|
902
903
|
|
|
903
|
-
<p
|
|
904
|
-
<a href="https://setup-php
|
|
905
|
-
<img src="https://setup-php.com/sponsors
|
|
904
|
+
<p>
|
|
905
|
+
<a href="https://www.jetbrains.com/?from=setup-php">
|
|
906
|
+
<img src="https://setup-php.com/sponsors/jetbrains.svg" alt="JetBrains" width="106" height="60">
|
|
907
|
+
</a>
|
|
908
|
+
|
|
909
|
+
<a href="https://www.macstadium.com/opensource/members#gh-light-mode-only">
|
|
910
|
+
<img src="https://setup-php.com/sponsors/macstadium.png" alt="Mac Stadium" width="148" height="60">
|
|
911
|
+
</a>
|
|
912
|
+
<a href="https://www.macstadium.com/opensource/members#gh-dark-mode-only">
|
|
913
|
+
<img src="https://setup-php.com/sponsors/macstadium-white.png" alt="Mac Stadium" width="148" height="60">
|
|
914
|
+
</a>
|
|
915
|
+
|
|
916
|
+
<a href="https://tidelift.com/subscription/pkg/npm-setup-php">
|
|
917
|
+
<img src="https://setup-php.com/sponsors/tidelift.png" alt="Tidelift" width="70" height="60">
|
|
906
918
|
</a>
|
|
907
919
|
</p>
|
|
908
920
|
|
|
@@ -934,6 +946,7 @@ Examples of using `setup-php` with various PHP Frameworks and Packages.
|
|
|
934
946
|
[`behat`]: https://docs.behat.org/en/latest/
|
|
935
947
|
[`blackfire`]: https://blackfire.io/docs/php/index
|
|
936
948
|
[`blackfire-player`]: https://blackfire.io/docs/builds-cookbooks/player
|
|
949
|
+
[`churn`]: https://github.com/bmitch/churn-php
|
|
937
950
|
[`codeception`]: https://codeception.com/
|
|
938
951
|
[`composer`]: https://getcomposer.org/
|
|
939
952
|
[`composer-normalize`]: https://github.com/ergebnis/composer-normalize
|