Skip to content

Commit

Permalink
Issue mikemadison13#8, don't overwrite existing files.
Browse files Browse the repository at this point in the history
  • Loading branch information
greggmarshall authored Feb 17, 2021
1 parent 41b7fa6 commit 6ced316
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/Blt/Plugin/Commands/LandoCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public function landoInit() {
$this->projectReadme = $this->getConfigValue('repo.root') . '/README.md';

$result = $this->taskFilesystemStack()
->copy($this->getConfigValue('repo.root') . '/vendor/mikemadison13/blt-lando/.lando.yml', $this->vmConfig, TRUE)
->copy($this->getConfigValue('repo.root') . '/vendor/mikemadison13/blt-lando/.lando.yml', $this->vmConfig, FALSE)
->stopOnFail()
->setVerbosityThreshold(VerbosityThresholdInterface::VERBOSITY_VERBOSE)
->run();
Expand All @@ -36,7 +36,7 @@ public function landoInit() {

// Create a project README file with Lando and BLT steps.
$result = $this->taskFilesystemStack()
->copy($this->getConfigValue('repo.root') . '/vendor/mikemadison13/blt-lando/example-README.md', $this->getConfigValue('repo.root') . '/README.md', true)
->copy($this->getConfigValue('repo.root') . '/vendor/mikemadison13/blt-lando/example-README.md', $this->getConfigValue('repo.root') . '/README.md', FALSE)
->setVerbosityThreshold(VerbosityThresholdInterface::VERBOSITY_VERBOSE)
->run();
if (!$result->wasSuccessful()) {
Expand All @@ -58,8 +58,8 @@ public function landoInit() {

// Copy BLT local config template (aka example.local.blt.yml).
$result = $this->taskFilesystemStack()
->copy($this->getConfigValue('repo.root') . '/vendor/mikemadison13/blt-lando/config/blt/example.local.blt.yml', $this->getConfigValue('repo.root') . '/blt/example.local.blt.yml', true)
->copy($this->getConfigValue('repo.root') . '/vendor/mikemadison13/blt-lando/config/blt/local.blt.yml', $this->getConfigValue('repo.root') . '/blt/local.blt.yml', true)
->copy($this->getConfigValue('repo.root') . '/vendor/mikemadison13/blt-lando/config/blt/example.local.blt.yml', $this->getConfigValue('repo.root') . '/blt/example.local.blt.yml', FALSE)
->copy($this->getConfigValue('repo.root') . '/vendor/mikemadison13/blt-lando/config/blt/local.blt.yml', $this->getConfigValue('repo.root') . '/blt/local.blt.yml', FALSE)
->setVerbosityThreshold(VerbosityThresholdInterface::VERBOSITY_VERBOSE)
->run();

Expand All @@ -86,8 +86,8 @@ public function landoInit() {
$this->invokeCommand('blt:init:settings');

$this->taskReplaceInFile($this->getConfigValue('docroot') . '/sites/default/settings/local.settings.php')
->from('drupal')
->to('drupal9')
->from('\'drupal\'')
->to('\'drupal9\'')
->run();
$this->taskReplaceInFile($this->getConfigValue('docroot') . '/sites/default/settings/local.settings.php')
->from("host' => 'localhost',")
Expand Down

0 comments on commit 6ced316

Please sign in to comment.