Beispiel #1
0
 public function getConfig($config, $tags, InputInterface $input)
 {
     $config = parent::getConfig($config, $tags, $input);
     $license = $tags['license'];
     if (isset($tags['license']) && $tags['license'] !== 'none') {
         if (isset($this->licenseAliases[$license])) {
             $license = $this->licenseAliases[$tags['license']];
         } else {
             $license = $tags['license'];
         }
         $config['composer.json']['license'] = $license;
     }
     return $config;
 }
Beispiel #2
0
 public function getConfig($config, $tags, InputInterface $input)
 {
     $authorArray = array();
     if ($author = $input->getOption('author')) {
         $authorArray['name'] = $author;
     }
     if ($email = $input->getOption('email')) {
         $authorArray['email'] = $email;
     }
     if (count($authorArray) > 0) {
         $this->addToConfig('composer.json', array('authors' => array($authorArray)));
     }
     if (isset($tags['tagline'])) {
         $this->config['composer.json']['description'] = $tags['tagline'];
     }
     return parent::getConfig($config, $tags, $input);
 }