Added the option to specify php-version: latest

This commit is contained in:
Marek Dědič 2020-10-03 13:55:11 +02:00
parent 8f0cfca455
commit 729fcb4756
No known key found for this signature in database
GPG Key ID: 032BEC49CE157DD2
2 changed files with 6 additions and 0 deletions

3
dist/index.js vendored
View File

@ -2506,6 +2506,9 @@ exports.build = build;
async function run() {
try {
let version = await utils.getInput('php-version', true);
if (version === 'latest') {
version = '7.4';
}
version = version.length > 1 ? version.slice(0, 3) : version + '.0';
const os_version = process.platform;
// check the os version and run the respective script

View File

@ -62,6 +62,9 @@ export async function build(
export async function run(): Promise<void> {
try {
let version: string = await utils.getInput('php-version', true);
if (version === 'latest') {
version = '7.4';
}
version = version.length > 1 ? version.slice(0, 3) : version + '.0';
const os_version: string = process.platform;