summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimon Rettberg2017-01-13 12:27:43 +0100
committerSimon Rettberg2017-01-13 12:27:43 +0100
commit5a9b589515fa795a629d721bdbf4ef51bb8cf2ec (patch)
tree88379d93197f37374880798d893ed15f5a8a49f8
parent[kernel-vanilla] 4.9.2 (diff)
downloadtm-scripts-5a9b589515fa795a629d721bdbf4ef51bb8cf2ec.tar.gz
tm-scripts-5a9b589515fa795a629d721bdbf4ef51bb8cf2ec.tar.xz
tm-scripts-5a9b589515fa795a629d721bdbf4ef51bb8cf2ec.zip
ULTRASTRACKE
-rwxr-xr-xuseful/ultrastrace.php57
1 files changed, 38 insertions, 19 deletions
diff --git a/useful/ultrastrace.php b/useful/ultrastrace.php
index 3c93f1cc..f0a3f0da 100755
--- a/useful/ultrastrace.php
+++ b/useful/ultrastrace.php
@@ -20,6 +20,12 @@ if ($argv[0] == '-u') {
$unique = true;
}
+$brief = false;
+if ($argv[0] == '-b') {
+ array_shift($argv);
+ $brief = true;
+}
+
foreach ($argv as $fname) {
$fh = fopen($fname, 'r');
if ($fh === false) die("File not found: $fname\n");
@@ -69,27 +75,40 @@ foreach ($argv as $fname) {
fclose($fh);
}
-echo "│\n│\n│\n│ ******* Found libraries *******************************************************\n";
-foreach ($found as $key => $val) {
- echo "│\n├──┬ $key\n";
- $count = count($val);
- $i = 1;
- foreach ($val as $loc) {
- if ($i == $count) echo "│ ╰── $loc\n";
- else echo "│ ├── $loc\n";
- ++$i;
+if ($brief) {
+
+ foreach ($found as $key => $val) {
+ echo "Found: $key\n";
+ }
+ foreach ($failed as $key => $val) {
+ echo "Missing: $key\n";
}
-}
-echo "│\n│\n│\n│ ******* Missing libraries *****************************************************\n";
-foreach ($failed as $key => $val) {
- echo "│\n├──┬ $key\n";
- $count = count($val);
- $i = 1;
- foreach ($val as $loc) {
- if ($i == $count) echo "│ ╰── $loc\n";
- else echo "│ ├── $loc\n";
- ++$i;
+} else {
+
+ echo "│\n│\n│\n│ ******* Found libraries *******************************************************\n";
+ foreach ($found as $key => $val) {
+ echo "│\n├──┬ $key\n";
+ $count = count($val);
+ $i = 1;
+ foreach ($val as $loc) {
+ if ($i == $count) echo "│ ╰── $loc\n";
+ else echo "│ ├── $loc\n";
+ ++$i;
+ }
+ }
+
+ echo "│\n│\n│\n│ ******* Missing libraries *****************************************************\n";
+ foreach ($failed as $key => $val) {
+ echo "│\n├──┬ $key\n";
+ $count = count($val);
+ $i = 1;
+ foreach ($val as $loc) {
+ if ($i == $count) echo "│ ╰── $loc\n";
+ else echo "│ ├── $loc\n";
+ ++$i;
+ }
}
+
}