changeset 78:e182d4ea85ca

*** empty log message ***
author ht
date Sun, 10 Jan 2010 15:13:57 +0000
parents cd7d748fbb09
children 8136660be547
files summa/concord
diffstat 1 files changed, 34 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/summa/concord	Sun Jan 10 15:13:57 2010 +0000
@@ -0,0 +1,34 @@
+#!/bin/sh
+if [ "$1" = "-b" ]
+then
+ shift
+ bi=1
+ tb="Bilingual c"
+ ff=bilingual/FP_ii.html
+ pat='x:div[@class="bilingual"][.//x:p[.~"'$1'"]]'
+else
+ bi=0
+ tb="C"
+ ff=latin/sth????.html
+ pat='x:p[.~"'$1'"]'
+fi
+egrep -l "\b$1" /home/ht/My\ Documents/Aquinas/summa/$ff | tr '\012' '\000' | \
+ xargs -0 lxgrep -xmlns:x="http://www.w3.org/1999/xhtml" -w x:div $pat  | \
+ sed "s/\(\b$1\w*\)/<b>\1<\/b>/;
+      s/<x:/</g; s/<\/x:/<\//g;
+      s/xmlns:x/xmlns/;
+      1i \
+<html xmlns='http://www.w3.org/1999/xhtml'>\
+<head>\
+<title>${tb}oncordance for $1</title>\
+<style>\
+ h2, h3, h4 {margin-bottom: 0px; clear: both}\
+ .bilingual {clear: both; margin-top: .5em}\
+ div.eng {width: 45%; float: left}\
+ div.lat {width: 45%; float: right}\
+</style>\
+</head>\
+<body>\
+"
+echo "</body></html>"
+