summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--modules/geneve/books66
-rwxr-xr-xmodules/geneve/transform.pl36
2 files changed, 102 insertions, 0 deletions
diff --git a/modules/geneve/books b/modules/geneve/books
new file mode 100644
index 0000000..b45de57
--- /dev/null
+++ b/modules/geneve/books
@@ -0,0 +1,66 @@
+GEN
+EXO
+LEV
+NUM
+DEU
+JOS
+JDG
+RUT
+1sa
+2SA
+1KI
+2KI
+1CH
+2CH
+EZR
+NEH
+EST
+JOB
+PSA
+PRO
+ECC
+SNG
+ISA
+LAM
+EZK
+DAN
+HOS
+JOL
+AMO
+OBA
+JON
+MIC
+NAM
+HAB
+ZEP
+HAG
+ZEC
+MAL
+MAT
+MRK
+LUK
+LUK
+JHN
+ACT
+ROM
+1CO
+2CO
+GAL
+EPH
+PHP
+COL
+1TH
+2TH
+1TI
+2TI
+TIT
+PHM
+HEB
+JAS
+1PE
+2PE
+1JN
+2JN
+3JN
+JUD
+REV
diff --git a/modules/geneve/transform.pl b/modules/geneve/transform.pl
new file mode 100755
index 0000000..89c5a94
--- /dev/null
+++ b/modules/geneve/transform.pl
@@ -0,0 +1,36 @@
+#!/usr/bin/perl
+
+my @files=`ls -1 *.abw`;
+my @ident=`cat books`;
+
+foreach (@files){
+
+ my @lines;
+ chop;
+ open USFM, ">>$_.u";
+ chomp(@lines=`cat $_`);
+
+ @lines[1]="\\id @ident[$_-1] ";
+
+ foreach (@lines) {
+ s/<m\ .*?\/m>//;
+ s/props\=\".*?\"//g;
+ s/<p\ style=\"Kapitel\".*?><c.*?>(.*?)<\/c><\/p>/\n\\c\ $1\ \n\\v\ 1\ /g;
+ s/<p\ style=\"Psalm Nr\".*?><c.*?>Psalm\ (.*?)<\/c><\/p>/\n\\c\ $1\n\\s1\ Psalm\ $1\n/g;
+ s/<c\ style=\"Verszahl\".*?>/\n\\v\ /g;
+ s/<p\ style=\"Buchtitel\".*?>/\n\\mt\ /g;
+ s/<p\ style=\"Bucheinleitung\".*?>/\n\\imt\n\\ip\ /g;
+ s/<p\ style=\"Spaltentitel\".*?>(.*?)<\/p>/\n\\s2\ $1\n\\p/g;
+ s/<p\ style=\"Spaltenparallelen\".*?>(.*?)<\/p>/\n\\r\ $1\n\\p/g;
+ s/<p style=\"Footnote Text\".*><field\ footnote-id=\".*?\"/\ \\f\ +\ /g;
+ s/<\/foot>/\\f\*\ /g;
+ s/type=\"footnote_anchor\"\ style=\"\"\ xid=\".*?\"\ >//g;
+ s/\\r\ Kapitel/\\mr Kapitel/g;
+ s/xid\=\".*?\"//g;
+ s/<.*?>//g;
+
+ }
+
+ print (USFM @lines);
+ close USFM;
+}