code: public function actionConfig($filePath)
      {
          $filePath = Yii::getAlias($filePath);
          $dir = dirname($filePath);
  
          if (file_exists($filePath)) {
              if (!$this->confirm("File '{$filePath}' already exists. Do you wish to overwrite it?")) {
                  return ExitCode::OK;
              }
          }
  
          $array = VarDumper::export($this->getOptionValues($this->action->id));
          $content = <<<EOD
  <?php
  /**
   * Configuration file for 'yii {$this->id}/{$this->defaultAction}' command.
   *
   * This file is automatically generated by 'yii {$this->id}/{$this->action->id}' command.
   * It contains parameters for source code messages extraction.
   * You may modify this file to suit your needs.
   *
   * You can use 'yii {$this->id}/{$this->action->id}-template' command to create
   * template configuration file with detailed description for each parameter.
   */
  return $array;
  
  EOD;
  
          if (FileHelper::createDirectory($dir) === false || file_put_contents($filePath, $content, LOCK_EX) === false) {
              $this->stdout("Configuration file was NOT created: '{$filePath}'.\n\n", Console::FG_RED);
              return ExitCode::UNSPECIFIED_ERROR;
          }
  
          $this->stdout("Configuration file created: '{$filePath}'.\n\n", Console::FG_GREEN);
          return ExitCode::OK;
      }
docs: Creates a configuration file for the "extract" command using command line options specified.
  
  The generated configuration file contains parameters required
  for source code messages extraction.
  You may use this configuration file with the "extract" command.
  
  @param string $filePath output file name or alias.
  @return int CLI exit code
  @throws Exception on failure.