mirror of
https://github.com/shivammathur/setup-php.git
synced 2025-07-23 23:29:07 +07:00
Add blackfire to linux install
Add logging about install process Fix formating of semversion blackfire Only add version when needed Pass phpversion
This commit is contained in:
24
dist/index.js
vendored
24
dist/index.js
vendored
@ -1247,6 +1247,17 @@ function suppressOutput(os_version) {
|
||||
});
|
||||
}
|
||||
exports.suppressOutput = suppressOutput;
|
||||
function getMinorVersion(version) {
|
||||
return __awaiter(this, void 0, void 0, function* () {
|
||||
const regex = /^\d+\.\d+/;
|
||||
const match = version.match(regex);
|
||||
if (match === null) {
|
||||
return version;
|
||||
}
|
||||
return match[0];
|
||||
});
|
||||
}
|
||||
exports.getMinorVersion = getMinorVersion;
|
||||
|
||||
|
||||
/***/ }),
|
||||
@ -2810,6 +2821,19 @@ function addExtensionLinux(extension_csv, version, pipe) {
|
||||
const prefix = yield utils.getExtensionPrefix(ext_name);
|
||||
let install_command = '';
|
||||
switch (true) {
|
||||
// match blackfire... blackfire-1.31.0
|
||||
case /^blackfire(-\d+\.\d+\.\d+)?$/.test(extension):
|
||||
script +=
|
||||
'\nsh ' +
|
||||
path.join(__dirname, '../src/scripts/ext/blackfire.sh') +
|
||||
' ' +
|
||||
version +
|
||||
' ' +
|
||||
(yield utils.getMinorVersion(version)).replace('.', '');
|
||||
if (ext_version) {
|
||||
script += ' ' + ext_version;
|
||||
}
|
||||
return;
|
||||
// match pre-release versions
|
||||
case /.*-(beta|alpha|devel|snapshot)/.test(version_extension):
|
||||
script +=
|
||||
|
Reference in New Issue
Block a user