public function build() {
    $this->say("Generating build artifact...");
    $this->say("For more detailed output, use the -v flag.");

    $commands = [
      // Execute `blt source:build:frontend` to ensure that frontend artifact
      // are generated in source repo.
      'source:build:frontend',
      // Execute `drupal:hash-salt:init` to ensure that salt.txt exists.
      // There's a slim chance this has never been generated.
      'drupal:hash-salt:init',
    ];
    if (!empty($this->tagName)) {
      $commands['drupal:deployment-identifier:init'] = ['--id' => $this->tagName];
    }
    else {
      $commands[] = 'drupal:deployment-identifier:init';
    }
    $this->invokeCommands($commands);

    $this->buildCopy();
    $this->composerInstall();
    $this->sanitize();
    $this->deploySamlConfig();
    $this->invokeHook("post-deploy-build");
    $this->say("<info>The deployment artifact was generated at {$this->deployDir}.</info>");
  }