aboutsummaryrefslogtreecommitdiff
path: root/phlogmap
diff options
context:
space:
mode:
Diffstat (limited to 'phlogmap')
-rwxr-xr-xphlogmap20
1 files changed, 20 insertions, 0 deletions
diff --git a/phlogmap b/phlogmap
new file mode 100755
index 0000000..211eb28
--- /dev/null
+++ b/phlogmap
@@ -0,0 +1,20 @@
+#!/usr/bin/env bash
+# build gophermap
+
+cd $HOME/src/gopher/phlog
+
+echo "+-----------------------------------+" > gophermap
+echo "| Phil's Phlog |" >> gophermap
+echo "+-----------------------------------+" >> gophermap
+echo "" >> gophermap
+echo "0[Rss feed] /phlog/rss.xml spike.nagatha.fr 70" >> gophermap
+echo "" >> gophermap
+
+dirs=($(ls -dr */))
+for dir in "${dirs[@]}"; do
+ dt=$(echo $dir| cut -c 1-10)
+ title="$(head -n 1 $dir/gophermap)"
+ echo -e "1$dt $title\t/phlog/$dir\tspike.nagatha.fr\t70" >> gophermap
+done
+
+exit 0