summaryrefslogtreecommitdiffstats
path: root/external/tgz/list.php
diff options
context:
space:
mode:
Diffstat (limited to 'external/tgz/list.php')
-rw-r--r--external/tgz/list.php24
1 files changed, 24 insertions, 0 deletions
diff --git a/external/tgz/list.php b/external/tgz/list.php
new file mode 100644
index 00000000..5c8d1c67
--- /dev/null
+++ b/external/tgz/list.php
@@ -0,0 +1,24 @@
+<?php
+
+/*
+echo '[';
+
+$first = true;
+foreach (glob('./*.tgz') as $file) {
+ if (!$first) echo ', ';
+ $first = false;
+ echo ' { "file" : "' . basename($file) . '", "description" : "<Beschreibung>" }';
+}
+echo ' ]';
+*/
+
+$files = array();
+foreach (glob('./*.tgz') as $file) {
+ $files[] = array(
+ 'file' => basename($file),
+ 'description' => 'Eine sinnvolle Beschreibung'
+ );
+}
+
+echo json_encode($files);
+