From 1cff99cbe3656637b58d0bb2b0086476aa49ac2e Mon Sep 17 00:00:00 2001
From: ​
Date: Thu, 1 Jan 1970 00:00:00 +0000
Subject: nift

---
 gen | 19 -------------------
 1 file changed, 19 deletions(-)
 delete mode 100755 gen

(limited to 'gen')

diff --git a/gen b/gen
deleted file mode 100755
index 31acfa4..0000000
--- a/gen
+++ /dev/null
@@ -1,19 +0,0 @@
-#!/usr/bin/env sh
-# generate site
-find -name "m.htm" -exec sh -c '
-	title=$(head -n1 ${1%/*}/m.htm | cut -d, -f1)
-	subdir=$(head -n1 ${1%/*}/m.htm | cut -d, -f2)
-	redirect=$(head -n1 ${1%/*}/m.htm | cut -d, -f3)
-	(cat h.htm; tail -n+2 ${1%/*}/m.htm; cat f.htm) >${1%/*}/index.html
-	sed -i "s,<title>,<title>$title," ${1%/*}/index.html
-	sed -i "s,href=\"//,href=\"http://,g" ${1%/*}/index.html
-	sed -i "s,href=\"/,href=\"$subdir,g" ${1%/*}/index.html
-	sed -i "s,src=\"/,src=\"$subdir,g" ${1%/*}/index.html
-	sed -zi "s,\n,,g" ${1%/*}/index.html
-	if [ "$(head -n1 ${1%/*}/m.htm | tr -cd ",")" = ",," ];
-	then
-		sed -i "s,8\",8\"\ \/\>\<meta\ http-equiv=\"refresh\"\ content=\"0\;url=$redirect\"," ${1%/*}/index.html
-	fi
-' sh {} \;
-sed "s/\.\.\///g" e/index.html >err.html
-cp err.html 404.html
-- 
cgit 1.4.1