2 namespace Composer\Installers;
5 * Plugin/theme installer for majima
6 * @author David Neustadt
8 class MajimaInstaller extends BaseInstaller
10 protected $locations = array(
11 'plugin' => 'plugins/{$name}/',
15 * Transforms the names
19 public function inflectPackageVars($vars)
21 return $this->correctPluginName($vars);
25 * Change hyphenated names to camelcase
29 private function correctPluginName($vars)
31 $camelCasedName = preg_replace_callback('/(-[a-z])/', function ($matches) {
32 return strtoupper($matches[0][1]);
34 $vars['name'] = ucfirst($camelCasedName);