Mercurial > hg > isophonics-drupal-site
view vendor/composer/installers/src/Composer/Installers/SiteDirectInstaller.php @ 12:7a779792577d
Update Drupal core to v8.4.5 (via Composer)
author | Chris Cannam |
---|---|
date | Fri, 23 Feb 2018 15:52:07 +0000 |
parents | |
children |
line wrap: on
line source
<?php namespace Composer\Installers; class SiteDirectInstaller extends BaseInstaller { protected $locations = array( 'module' => 'modules/{$vendor}/{$name}/', 'plugin' => 'plugins/{$vendor}/{$name}/' ); public function inflectPackageVars($vars) { return $this->parseVars($vars); } protected function parseVars($vars) { $vars['vendor'] = strtolower($vars['vendor']) == 'sitedirect' ? 'SiteDirect' : $vars['vendor']; $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']); $vars['name'] = str_replace(' ', '', ucwords($vars['name'])); return $vars; } }