Merge pull request #2509 from glenjamin/opcache-ext
Ensure detected extensions have valid package namespull/2512/head
commit
0e9a9a3875
|
@ -70,7 +70,8 @@ class PlatformRepository extends ArrayRepository
|
||||||
$version = $versionParser->normalize($prettyVersion);
|
$version = $versionParser->normalize($prettyVersion);
|
||||||
}
|
}
|
||||||
|
|
||||||
$ext = new CompletePackage('ext-'.$name, $version, $prettyVersion);
|
$packageName = $this->buildPackageName($name);
|
||||||
|
$ext = new CompletePackage($packageName, $version, $prettyVersion);
|
||||||
$ext->setDescription('The '.$name.' PHP extension');
|
$ext->setDescription('The '.$name.' PHP extension');
|
||||||
parent::addPackage($ext);
|
parent::addPackage($ext);
|
||||||
}
|
}
|
||||||
|
@ -159,4 +160,10 @@ class PlatformRepository extends ArrayRepository
|
||||||
parent::addPackage($hhvm);
|
parent::addPackage($hhvm);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private function buildPackageName($name)
|
||||||
|
{
|
||||||
|
return 'ext-' . str_replace(' ', '-', $name);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue