New error detection: composer has not been installed
This commit is contained in:
parent
7b556f1e12
commit
124c339d5b
6 changed files with 31 additions and 6 deletions
|
@ -35,7 +35,11 @@ if(file_exists(getcwd() . "/Core")) {
|
|||
define("PROJECT_PATH_ROOT", dirname(getcwd()) . "/"); #../
|
||||
}
|
||||
|
||||
require PROJECT_PATH_ROOT . '/vendor/autoload.php';
|
||||
if(!file_exists(PROJECT_PATH_ROOT . 'vendor/')) {
|
||||
die('<h1>Incomplete installation</h1><p>Baïkal dependancies have not been installed. Please, execute "<strong>composer install</strong>" in the folder where you installed Baïkal.');
|
||||
}
|
||||
|
||||
require PROJECT_PATH_ROOT . 'vendor/autoload.php';
|
||||
|
||||
# Bootstraping Flake
|
||||
\Flake\Framework::bootstrap();
|
||||
|
|
|
@ -35,7 +35,11 @@ if(file_exists(getcwd() . "/Core")) {
|
|||
define("PROJECT_PATH_ROOT", dirname(getcwd()) . "/"); #../
|
||||
}
|
||||
|
||||
require PROJECT_PATH_ROOT . '/vendor/autoload.php';
|
||||
if(!file_exists(PROJECT_PATH_ROOT . 'vendor/')) {
|
||||
die('<h1>Incomplete installation</h1><p>Baïkal dependancies have not been installed. Please, execute "<strong>composer install</strong>" in the folder where you installed Baïkal.');
|
||||
}
|
||||
|
||||
require PROJECT_PATH_ROOT . 'vendor/autoload.php';
|
||||
|
||||
# Bootstraping Flake
|
||||
\Flake\Framework::bootstrap();
|
||||
|
|
|
@ -34,7 +34,11 @@ if(file_exists(getcwd() . "/Core")) {
|
|||
define("PROJECT_PATH_ROOT", dirname(getcwd()) . "/"); #../
|
||||
}
|
||||
|
||||
require PROJECT_PATH_ROOT . '/vendor/autoload.php';
|
||||
if(!file_exists(PROJECT_PATH_ROOT . 'vendor/')) {
|
||||
die('<h1>Incomplete installation</h1><p>Baïkal dependancies have not been installed. Please, execute "<strong>composer install</strong>" in the folder where you installed Baïkal.');
|
||||
}
|
||||
|
||||
require PROJECT_PATH_ROOT . 'vendor/autoload.php';
|
||||
|
||||
# Bootstraping Flake
|
||||
\Flake\Framework::bootstrap();
|
||||
|
|
|
@ -34,8 +34,12 @@ class Initialize extends \Flake\Core\Controller {
|
|||
|
||||
public function execute() {
|
||||
# Assert that /Specific is writable
|
||||
|
||||
if(!file_exists(PROJECT_PATH_SPECIFIC) || !is_dir(PROJECT_PATH_SPECIFIC) || !is_writable(PROJECT_PATH_SPECIFIC)) {
|
||||
throw new \Exception("Specific/ dir is readonly. Baïkal Admin requires write permissions on this dir.");
|
||||
$message = "<h1>Error - Insufficient permissions on the <span style='background-color: yellow;'>Specific/</span> folder</h1><p>";
|
||||
$message .= "<p>In order to work properly, Baïkal needs to have write permissions in the <strong>Specific/</strong> folder.</p>";
|
||||
|
||||
die($message);
|
||||
}
|
||||
|
||||
$this->createHtaccessFilesIfNeeded();
|
||||
|
|
|
@ -39,7 +39,11 @@ if(file_exists(dirname(getcwd()). "/Core")) {
|
|||
define("PROJECT_PATH_ROOT", dirname(dirname(getcwd())) . "/"); #../../
|
||||
}
|
||||
|
||||
require PROJECT_PATH_ROOT . '/vendor/autoload.php';
|
||||
if(!file_exists(PROJECT_PATH_ROOT . 'vendor/')) {
|
||||
die('<h1>Incomplete installation</h1><p>Baïkal dependancies have not been installed. Please, execute "<strong>composer install</strong>" in the folder where you installed Baïkal.');
|
||||
}
|
||||
|
||||
require PROJECT_PATH_ROOT . 'vendor/autoload.php';
|
||||
|
||||
# Bootstraping Flake
|
||||
\Flake\Framework::bootstrap();
|
||||
|
|
|
@ -39,8 +39,13 @@ if(file_exists(dirname(dirname(getcwd())) . "/Core")) {
|
|||
define("PROJECT_PATH_ROOT", dirname(dirname(dirname(getcwd()))) . "/"); # ../../../
|
||||
}
|
||||
|
||||
# Bootstraping Flake
|
||||
if(!file_exists(PROJECT_PATH_ROOT . 'vendor/')) {
|
||||
die('<h1>Incomplete installation</h1><p>Baïkal dependancies have not been installed. Please, execute "<strong>composer install</strong>" in the folder where you installed Baïkal.');
|
||||
}
|
||||
|
||||
require PROJECT_PATH_ROOT . "vendor/autoload.php";
|
||||
|
||||
# Bootstraping Flake
|
||||
\Flake\Framework::bootstrap();
|
||||
|
||||
# Bootstrap BaikalAdmin
|
||||
|
|
Loading…
Reference in a new issue