mirror of
https://github.com/icewind1991/nextcloud-version-matrix.git
synced 2026-06-03 09:34:12 +02:00
also generate full matrix
This commit is contained in:
parent
b706b8d35f
commit
d594a6929d
4 changed files with 47 additions and 6 deletions
17
dist/index.js
vendored
17
dist/index.js
vendored
|
|
@ -42656,10 +42656,20 @@ function copy(obj) {
|
|||
phpMatrix.forEach(row => {
|
||||
const php = row['php-versions'];
|
||||
const candidateVersion = versionData.findLast(data => data.phpMin <= php && data.phpMax >= php);
|
||||
console.log(php, candidateVersion);
|
||||
row["server-versions"] = candidateVersion.branch;
|
||||
});
|
||||
|
||||
// matrix with every php and server combination
|
||||
const fullMatrix = cartesianProduct({
|
||||
"server-versions": versionData.map(data => data.branch),
|
||||
"php-versions": php,
|
||||
...matrixInput
|
||||
}).filter(row => {
|
||||
const php = row['php-versions'];
|
||||
const version = versionData.find(version => version.branch === row['server-versions']);
|
||||
return version.phpMin <= php && version.phpMax >= php;
|
||||
});
|
||||
|
||||
// matrix with at least one item for every server and php version
|
||||
let testMatrix = phpMatrix.concat(serverMatrix).filter(onlyUnique);
|
||||
|
||||
|
|
@ -42682,9 +42692,12 @@ function copy(obj) {
|
|||
core.setOutput("matrix", JSON.stringify({
|
||||
include: serverMatrix
|
||||
}));
|
||||
core.setOutput("test-matrix", JSON.stringify({
|
||||
core.setOutput("sparse-matrix", JSON.stringify({
|
||||
include: testMatrix
|
||||
}));
|
||||
core.setOutput("full-matrix", JSON.stringify({
|
||||
include: fullMatrix
|
||||
}));
|
||||
|
||||
core.setOutput("ocp-matrix", JSON.stringify({
|
||||
include: serverMatrix.map(row => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue