Skip to content

Commit ac8fdfe

Browse files
authored
Merge branch 'main' into feat/default-sec
2 parents 37ec479 + 221156c commit ac8fdfe

File tree

1 file changed

+60
-0
lines changed

1 file changed

+60
-0
lines changed
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
---
2+
title: "ignore_platform_requirements"
3+
date: 2026-01-25T10:00:00+01:00
4+
anchor: "ignore-platform-requirements"
5+
weight:
6+
---
7+
8+
## Configuration
9+
10+
<div className="config-wrapper"><div className="config">__name__: ignore_platform_requirements</div>
11+
<div className="config">__type__: int</div>
12+
<div className="config">__default__: 0</div></div>
13+
14+
```json showLineNumbers
15+
{
16+
"name": "company/project",
17+
"extra": {
18+
"violinist": {
19+
// highlight-next-line
20+
"ignore_platform_requirements": 0
21+
}
22+
}
23+
}
24+
```
25+
26+
Ignore PHP platform requirements when checking for updates.
27+
28+
## Explanation
29+
30+
When enabled, Violinist will set the `COMPOSER_IGNORE_PLATFORM_REQS` environment variable. This tells Composer to ignore platform requirements (PHP version, extensions, etc.) when resolving and updating dependencies.
31+
32+
This can be useful when the PHP version or extensions available in Violinist's environment differ from your production environment.
33+
34+
## Example
35+
36+
Say your production environment uses a PHP extension that isn't universally available. Without this option, Composer might refuse to update packages because the extension isn't present when checking for updates. To work around this, enable `ignore_platform_requirements`:
37+
38+
```json showLineNumbers
39+
{
40+
"name": "company/project",
41+
"description": "My awesome project",
42+
"require": {
43+
"php": "^8.2",
44+
"ext-acme": "*",
45+
"vendor/package": "~1.0.0"
46+
},
47+
"extra": {
48+
"violinist": {
49+
// highlight-next-line
50+
"ignore_platform_requirements": 1
51+
}
52+
}
53+
}
54+
```
55+
56+
:::note
57+
`ext-acme` is a fictional extension used for illustration purposes.
58+
:::
59+
60+
With this configuration, Violinist will ignore platform requirements and proceed with checking for updates. Your CI pipeline should still verify that the updated dependencies work correctly with your actual platform configuration.

0 commit comments

Comments
 (0)