You are here

public function ThemeGenerator::targetDirectory in AT Tool 2.0 1.0.x

Path to where we will save the theme and perform generator operations.

Return value

string

1 call to ThemeGenerator::targetDirectory()
ThemeGenerator::__construct in at_theme_generator/src/Theme/ThemeGenerator.php
Generator constructor.

File

at_theme_generator/src/Theme/ThemeGenerator.php, line 98

Class

ThemeGenerator
Generator form.

Namespace

Drupal\at_theme_generator\Theme

Code

public function targetDirectory() {
  if ($this->dir_option === 'custom') {
    $target_dir = $this->dir_option_custom;
  }
  elseif ($this->dir_option === 'public://') {
    $target_path = 'public://generated_themes';
    $target_dir = $this->directoryOperations
      ->directoryPrepare([
      $target_path,
    ]);
  }
  else {
    $target_dir = 'themes';
  }
  return $target_dir . '/' . $this->machine_name;
}