Mercurial > hg > isophonics-drupal-site
view vendor/composer/installers/src/Composer/Installers/OntoWikiInstaller.php @ 0:4c8ae668cc8c
Initial import (non-working)
author | Chris Cannam |
---|---|
date | Wed, 29 Nov 2017 16:09:58 +0000 |
parents | |
children |
line wrap: on
line source
<?php namespace Composer\Installers; class OntoWikiInstaller extends BaseInstaller { protected $locations = array( 'extension' => 'extensions/{$name}/', 'theme' => 'extensions/themes/{$name}/', 'translation' => 'extensions/translations/{$name}/', ); /** * Format package name to lower case and remove ".ontowiki" suffix */ public function inflectPackageVars($vars) { $vars['name'] = strtolower($vars['name']); $vars['name'] = preg_replace('/.ontowiki$/', '', $vars['name']); $vars['name'] = preg_replace('/-theme$/', '', $vars['name']); $vars['name'] = preg_replace('/-translation$/', '', $vars['name']); return $vars; } }