summaryrefslogtreecommitdiff
path: root/index.md.do
diff options
context:
space:
mode:
Diffstat (limited to 'index.md.do')
-rw-r--r--index.md.do18
1 files changed, 18 insertions, 0 deletions
diff --git a/index.md.do b/index.md.do
new file mode 100644
index 0000000..02c10af
--- /dev/null
+++ b/index.md.do
@@ -0,0 +1,18 @@
1#!/usr/bin/env bash
2LISTS=()
3while read -r -d $'\0'; do
4 LISTS+=("$REPLY")
5done < <(find lists -maxdepth 1 -mindepth 1 -type d -not -name '.*' -print0 | sort -z)
6
7for x in "${LISTS[@]}"; do
8 printf "%s.html\0" "$x"
9done | xargs -r -0 redo-ifchange
10
11cat <<EOF
12% Index
13
14EOF
15
16for x in "${LISTS[@]}"; do
17 printf "* [%s](%s)\n" "$(<$x/title)" "$x.html"
18done