From 3008c5da7eb19f23eae44f44f5471558e00c506b Mon Sep 17 00:00:00 2001 From: Miloslav Ciz Date: Sun, 28 Aug 2022 17:56:10 +0200 Subject: [PATCH] Update --- make_txt.sh | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100755 make_txt.sh diff --git a/make_txt.sh b/make_txt.sh new file mode 100755 index 0000000..a2bf29d --- /dev/null +++ b/make_txt.sh @@ -0,0 +1,33 @@ +#!/bin/sh +# Creates an ASXII version of the wiki. + +echo "making TXT" +rm -rf txt +mkdir txt + +for f in *.md; do + echo $f + + fname=$(echo "$f" | sed "s/\.md//g") + f2="txt/${fname}.txt" + + pandoc -f markdown -t plain $f | iconv -f utf-8 -t ascii//TRANSLIT >> $f2 +done + +echo "making single TXT" + +echo "LESS RETARDED WIKI" > lrs.txt +echo "by drummyfish, released under CC0 1.0, public domain" >> lrs.txt + +for f in txt/*.txt; do + echo $f + + fname=$(echo "$f" | sed "s/\.txt//g" | sed "s/txt\///g") + + echo "--------------------------------------------------------------------------------" >> lrs.txt + echo "$fname:" >> lrs.txt + + cat $f >> lrs.txt +done + +echo "done"