mirror of
https://github.com/shivammathur/setup-php.git
synced 2025-08-01 19:27:57 +07:00
Add support for nightly alias
This commit is contained in:
@ -1,5 +1,6 @@
|
||||
{
|
||||
"latest": "8.0",
|
||||
"nightly": "8.2",
|
||||
"5.x": "5.6",
|
||||
"7.x": "7.4",
|
||||
"8.x": "8.0"
|
||||
|
@ -102,7 +102,7 @@ export async function getManifestURL(): Promise<string> {
|
||||
export async function parseVersion(version: string): Promise<string> {
|
||||
const manifest = await getManifestURL();
|
||||
switch (true) {
|
||||
case /^(latest|\d+\.x)$/.test(version):
|
||||
case /^(latest|nightly|\d+\.x)$/.test(version):
|
||||
return JSON.parse((await fetch(manifest))['data'])[version];
|
||||
default:
|
||||
switch (true) {
|
||||
|
Reference in New Issue
Block a user