-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathrun.php
More file actions
25 lines (19 loc) · 662 Bytes
/
run.php
File metadata and controls
25 lines (19 loc) · 662 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
<?php
require __DIR__ . '/vendor/autoload.php';
use Keboola\Xls2CsvProcessor\Exception\UserException;
use Symfony\Component\Config\Definition\Exception\InvalidConfigurationException;
try {
$component = new \Keboola\Xls2CsvProcessor\Component();
$component->run();
} catch(UserException | InvalidConfigurationException $e) {
error_log($e->getMessage());
exit(1);
} catch(Throwable $e) {
error_log(get_class($e) . ': ' . $e->getMessage());
error_log('File: ' . $e->getFile());
error_log('Line: ' . $e->getLine());
error_log('Code: ' . $e->getCode());
error_log('Trace: ' . $e->getTraceAsString());
exit(2);
}
exit(0);