示例#1
0
 /**
  * Loop through all controller files in the bundles directory.
  *
  * @param  object \InputInterface
  * @param  object \OutputInterface
  * @return void
  */
 private function process(InputInterface $input, OutputInterface $output)
 {
     $dir = $this->config->get('bundles_dir');
     $finder = new Finder();
     $finder->in($dir)->name('*Controller.js');
     foreach ($finder as $file) {
         $filepath = $file->getRealPath();
         $basename = basename($filepath);
         // set final dep output file
         $outputFile = $this->config->get('build_dir') . '/' . $basename;
         $dependencies = Dependency::getDependencies($this->config, $filepath);
         Dependency::merge($this->config, $dependencies, $outputFile);
     }
 }