Keep sample bootstrap purely in samples

This commit is contained in:
Adrien Crivelli 2020-05-17 18:51:13 +09:00
parent cfb8b2f9e3
commit 5f413b8a58
No known key found for this signature in database
GPG Key ID: B182FD79DC6DE92E
8 changed files with 7 additions and 9 deletions

View File

@ -4,7 +4,7 @@
use PhpOffice\PhpSpreadsheet\Calculation\Calculation;
use PhpOffice\PhpSpreadsheet\DocumentGenerator;
require_once __DIR__ . '/../src/Bootstrap.php';
require_once 'vendor/autoload.php';
try {
$phpSpreadsheetFunctionsProperty = (new ReflectionClass(Calculation::class))->getProperty('phpSpreadsheetFunctions');
@ -19,6 +19,6 @@ try {
DocumentGenerator::generateFunctionListByName($phpSpreadsheetFunctions)
);
} catch (ReflectionException $e) {
fwrite(STDERR, (string)$e);
fwrite(STDERR, (string) $e);
exit(1);
}

View File

@ -4,7 +4,7 @@ use PhpOffice\PhpSpreadsheet\Helper\Sample;
use PhpOffice\PhpSpreadsheet\IOFactory;
use PhpOffice\PhpSpreadsheet\Spreadsheet;
require_once __DIR__ . '/../../src/Bootstrap.php';
require_once __DIR__ . '/../Bootstrap.php';
$helper = new Sample();
if ($helper->isCli()) {

View File

@ -4,7 +4,7 @@ use PhpOffice\PhpSpreadsheet\Helper\Sample;
use PhpOffice\PhpSpreadsheet\IOFactory;
use PhpOffice\PhpSpreadsheet\Spreadsheet;
require_once __DIR__ . '/../../src/Bootstrap.php';
require_once __DIR__ . '/../Bootstrap.php';
$helper = new Sample();
if ($helper->isCli()) {

View File

@ -4,7 +4,7 @@ use PhpOffice\PhpSpreadsheet\Helper\Sample;
use PhpOffice\PhpSpreadsheet\IOFactory;
use PhpOffice\PhpSpreadsheet\Spreadsheet;
require_once __DIR__ . '/../../src/Bootstrap.php';
require_once __DIR__ . '/../Bootstrap.php';
$helper = new Sample();
if ($helper->isCli()) {

View File

@ -4,7 +4,7 @@ use PhpOffice\PhpSpreadsheet\Helper\Sample;
use PhpOffice\PhpSpreadsheet\IOFactory;
use PhpOffice\PhpSpreadsheet\Spreadsheet;
require_once __DIR__ . '/../../src/Bootstrap.php';
require_once __DIR__ . '/../Bootstrap.php';
$helper = new Sample();
if ($helper->isCli()) {

View File

@ -6,7 +6,7 @@ use PhpOffice\PhpSpreadsheet\Helper\Sample;
error_reporting(E_ALL);
require_once __DIR__ . '/../src/Bootstrap.php';
require_once __DIR__ . '/Bootstrap.php';
$helper = new Sample();

View File

@ -4,5 +4,3 @@ setlocale(LC_ALL, 'en_US.utf8');
// PHP 5.3 Compat
date_default_timezone_set('Europe/London');
require_once __DIR__ . '/../src/Bootstrap.php';