We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b3e6e10 commit 002fc42Copy full SHA for 002fc42
1 file changed
bin/import.php
@@ -0,0 +1,24 @@
1
+#!/usr/bin/env php
2
+<?php
3
+
4
+use Xhgui\Profiler\ImporterFactory;
5
6
+require __DIR__ . '/../vendor/autoload.php';
7
8
+$importer = ImporterFactory::create();
9
10
+if ($argc <= 1) {
11
+ throw new RuntimeException('Missing input filename');
12
+}
13
14
+$filename = $argv[1];
15
+if (!is_readable($filename)) {
16
+ throw new RuntimeException($filename . ' isn\'t readable');
17
18
19
+$fp = fopen($filename, 'r');
20
+if (!$fp) {
21
+ throw new RuntimeException('Can\'t open ' . $filename);
22
23
+$importer->import($fp);
24
+fclose($fp);
0 commit comments