From 9fce418b46c9f0894f429384ef9e3dabaeffbeb4 Mon Sep 17 00:00:00 2001 From: Case Duckworth Date: Tue, 14 Apr 2015 16:36:17 -0700 Subject: Change file hierarchy and rewrite makefile - File hierarchy is now as follows: - / - appendix/ < appendix source files - backlinks/ < backlink sources & builds - hapax/ < *.hapax source files - scripts/ < scripts, like *.js, *.hs, etc. - templates/ < templates for outputs - text/ < source files - trunk/ < assets, like css, images, heads, etc. - index.html - *.html - Makefile --- trunk/hapaxlink.sh | 26 -------------------------- 1 file changed, 26 deletions(-) delete mode 100644 trunk/hapaxlink.sh (limited to 'trunk/hapaxlink.sh') diff --git a/trunk/hapaxlink.sh b/trunk/hapaxlink.sh deleted file mode 100644 index 286c43d..0000000 --- a/trunk/hapaxlink.sh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/bash - -file="$1"; -headFile="$2"; -shift 2; -glob="$@"; # *.hapax - -tempFile="${RANDOM}.tmp" - -echo -n "Linking \"$file\"" -# Begin -cat "$headFile" > "$tempFile"; -echo -n "." -# Link words to files they appear in -for word in `sort "$file"`; do - f=`grep -liwq "^$word$" $glob`; - link="`basename $f .hapax`.html" - echo "[$word]($link)" >> "$tempFile"; - echo -n "." -done - -# Make the changes happen -rm "$file" -mv "$tempFile" "$file" - -echo "Done." -- cgit 1.4.1-21-gabe81