diff options
author | VirtualTam <virtualtam@flibidi.net> | 2016-09-06 19:17:23 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-09-06 19:17:23 +0200 |
commit | d06c28ef64c96c40f627503a27ea224947e288f0 (patch) | |
tree | ff5d3a30e6e0a222f808d0663deef2e69c65b1dc /index.php | |
parent | e1fd94b545a6783853eeee03264596111fdf767e (diff) | |
parent | 5283175367638850d34124afd336ccfcb6884723 (diff) | |
download | Shaarli-d06c28ef64c96c40f627503a27ea224947e288f0.tar.gz Shaarli-d06c28ef64c96c40f627503a27ea224947e288f0.tar.zst Shaarli-d06c28ef64c96c40f627503a27ea224947e288f0.zip |
Merge pull request #646 from virtualtam/composer/check-autoload
composer: display an error message if the autoload script is missing
Diffstat (limited to 'index.php')
-rw-r--r-- | index.php | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -45,6 +45,16 @@ error_reporting(E_ALL^E_WARNING); | |||
45 | 45 | ||
46 | 46 | ||
47 | // 3rd-party libraries | 47 | // 3rd-party libraries |
48 | if (! file_exists(__DIR__ . '/vendor/autoload.php')) { | ||
49 | header('Content-Type: text/plain; charset=utf-8'); | ||
50 | echo "Error: missing Composer configuration\n\n" | ||
51 | ."If you installed Shaarli through Git or using the development branch,\n" | ||
52 | ."please refer to the installation documentation to install PHP" | ||
53 | ." dependencies using Composer:\n" | ||
54 | ."- https://github.com/shaarli/Shaarli/wiki/Server-requirements\n" | ||
55 | ."- https://github.com/shaarli/Shaarli/wiki/Download-and-Installation"; | ||
56 | exit; | ||
57 | } | ||
48 | require_once 'inc/rain.tpl.class.php'; | 58 | require_once 'inc/rain.tpl.class.php'; |
49 | require_once __DIR__ . '/vendor/autoload.php'; | 59 | require_once __DIR__ . '/vendor/autoload.php'; |
50 | 60 | ||