mirror of
https://github.com/icewind1991/nextcloud-version-matrix.git
synced 2026-06-03 17:44:08 +02:00
check for branched version instead of releases:
This commit is contained in:
parent
b9b8f0b2b3
commit
d43cc64aae
2 changed files with 4 additions and 4 deletions
|
|
@ -15,7 +15,7 @@ List of version number the app supports
|
||||||
|
|
||||||
### `branches`
|
### `branches`
|
||||||
|
|
||||||
Branches for each supported version, either `stableXX` or `master` for versions that aren't released yet
|
Branches for each supported version, either `stableXX` or `master` for versions that aren't branched yet.
|
||||||
|
|
||||||
## License
|
## License
|
||||||
[MIT License](LICENSE.md)
|
[MIT License](LICENSE.md)
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ const DOMParser = require('xmldom').DOMParser;
|
||||||
const fs = require('fs');
|
const fs = require('fs');
|
||||||
const urlExist = require('url-exist');
|
const urlExist = require('url-exist');
|
||||||
|
|
||||||
function isVersionReleased(version) {
|
function versionHashBranch(version) {
|
||||||
return urlExist(`https://download.nextcloud.com/server/releases/latest-${version}.zip`);
|
return urlExist(`https://github.com/nextcloud/server/tree/stable${version}`);
|
||||||
}
|
}
|
||||||
|
|
||||||
function range(from, to) {
|
function range(from, to) {
|
||||||
|
|
@ -31,7 +31,7 @@ function onlyUnique(value, index, array) {
|
||||||
core.setOutput("versions", JSON.stringify(versions));
|
core.setOutput("versions", JSON.stringify(versions));
|
||||||
|
|
||||||
const branches = await Promise.all(versions.map(async (version) => {
|
const branches = await Promise.all(versions.map(async (version) => {
|
||||||
if (await isVersionReleased(version)) {
|
if (await versionHashBranch(version)) {
|
||||||
return `stable${version}`;
|
return `stable${version}`;
|
||||||
} else {
|
} else {
|
||||||
return "master";
|
return "master";
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue