Specify PHP version when installing ast

This commit is contained in:
Shivam Mathur 2020-10-13 11:02:43 +05:30
parent a0f02c17c0
commit d2241010ef
No known key found for this signature in database
GPG Key ID: 3E13E4C8591ACC2A
3 changed files with 5 additions and 5 deletions

View File

@ -70,7 +70,7 @@ describe('Extension tests', () => {
'sudo $debconf_fix apt-get install -y php7.4-sqlite3'
);
expect(linux).toContain('remove_extension intl');
expect(linux).toContain('sudo $debconf_fix apt-get install -y php-ast');
expect(linux).toContain('sudo $debconf_fix apt-get install -y php7.4-ast');
expect(linux).toContain('sudo $debconf_fix apt-get install -y php-uopz');
expect(linux).toContain('add_unstable_extension ast beta extension');
expect(linux).toContain('add_pdo_extension mysql');

4
dist/index.js vendored
View File

@ -3052,8 +3052,8 @@ async function addExtensionLinux(extension_csv, version, pipe) {
extension = extension.replace(/pdo[_-]|3/, '');
add_script += '\nadd_pdo_extension ' + extension;
return;
// match ast and uopz
case /^(ast|uopz)$/.test(extension):
// match uopz
case /^(uopz)$/.test(extension):
command = command_prefix + '-' + extension + pipe;
break;
// match sqlite

View File

@ -295,8 +295,8 @@ export async function addExtensionLinux(
extension = extension.replace(/pdo[_-]|3/, '');
add_script += '\nadd_pdo_extension ' + extension;
return;
// match ast and uopz
case /^(ast|uopz)$/.test(extension):
// match uopz
case /^(uopz)$/.test(extension):
command = command_prefix + '-' + extension + pipe;
break;
// match sqlite