Skip to content
This repository has been archived by the owner on Jan 19, 2023. It is now read-only.

Commit

Permalink
Updated symlink
Browse files Browse the repository at this point in the history
  • Loading branch information
ajthinking committed May 8, 2018
1 parent 13ac72d commit ab4b4a2
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 10 deletions.
3 changes: 2 additions & 1 deletion app/Console/Commands/HomeCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ public function handle()
/_/';

$this->line($logo);
$this->line("\n By stimpack.io and contributors 2017-" . date("Y") . "\n");
$this->info("\n By stimpack.io and contributors 2017-" . date("Y") . "\n");
$this->line("You are running stimpack from: " . base_path() . "\n");
}
}
21 changes: 12 additions & 9 deletions app/Console/Commands/ParkCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,14 +41,17 @@ public function handle()

protected function createSymlinkToCode()
{
$this->info("Create symlink with");
$this->info("FROM: " . base_path("../stimpack"));
$this->info("TO: " . $this->parkAt . "/stimpack");

symlink(
base_path("../stimpack"), // Target
$this->parkAt . "/stimpack" // Link
);
$from = base_path();
$to = $this->parkAt . "/stimpack";

// Delete existing link. Scenarios:
// Deploying the stimpack-dev version
// Redeploying the globally installed version
if(is_link($to)){
unlink($to);
}

$this->info("Create symlink from $from to $to");
symlink($from, $to);
}

}

0 comments on commit ab4b4a2

Please sign in to comment.