diff --git a/MAST_tW_PDF_Updater/FilesForUpdates/Exceptions/Exceptions_tWs_from_OSHB.txt b/MAST_tW_PDF_Updater/FilesForUpdates/Exceptions/Exceptions_tWs_from_OSHB.txt
index 6c5296e..5a22e9e 100644
--- a/MAST_tW_PDF_Updater/FilesForUpdates/Exceptions/Exceptions_tWs_from_OSHB.txt
+++ b/MAST_tW_PDF_Updater/FilesForUpdates/Exceptions/Exceptions_tWs_from_OSHB.txt
@@ -664,7 +664,7 @@ Ezra 7:28 3289 counselors
Ezra 7:28 2388 ||
Ezra 7:28 5927 ||
Ezra 8:1 5927 ||
-Ezra 8:3 3187
+Ezra 8:3 3187 ||
Ezra 8:3 2145
Ezra 8:4 2145
Ezra 8:5 2145
diff --git a/MAST_tW_PDF_Updater/FilesForUpdates/Mine.URL.Strong.Verse.OT.2.pl b/MAST_tW_PDF_Updater/FilesForUpdates/Mine.URL.Strong.Verse.OT.2.pl
index 76228da..1ec987e 100644
--- a/MAST_tW_PDF_Updater/FilesForUpdates/Mine.URL.Strong.Verse.OT.2.pl
+++ b/MAST_tW_PDF_Updater/FilesForUpdates/Mine.URL.Strong.Verse.OT.2.pl
@@ -12,12 +12,12 @@ use FindBin '$Bin';
use Cwd ;
my ($d) = ("\\");
-my ($workDir, $textEditor, $repoPath, $browser, $blbRef) = ($Bin, "\\");
+my ($workDir, $textEditor, $repoPath, $browser, $blbRef, $tN_page) = ($Bin, "\\");
my %abbr;
if ($^O eq "darwin" || $^O eq "linux") {$d = "/"}
-open LOG, ">:utf8", "Logs${d}mine_log.log" or die ("$!");
+open LOG, ">:utf8", "$Bin${d}Logs${d}mine_log.log" or die ("$!:\n$Bin$[d}Logs${d}mine_log.log");
while () {
chomp;
@@ -47,8 +47,8 @@ my ($excFile, $topDir, $txtFile, $dataFile, $displayFile, $filePattern, $sn, $xf
"*\.md"
);
-my ($missingLine, $bk, $ch, $vs, $ref, $strong, $word, $flag, $tNid, $abbr, $doFlag, $xmlFile, $outputFiles, $lbsBk);
-my (%bkAbr, %wa);
+my ($missingLine, $bk, $ch, $vs, $ref, $strong, $word, $flag, $tNid, $abbr, $doFlag, $xmlFile, $lbsBk);
+my (%bkAbr, %wa, %tW_file);
my @tWfiles;
find( sub { push @tWfiles, $File::Find::name if ( m/^(.*)$filePattern$/ ) }, $topDir) ;
@@ -81,11 +81,13 @@ sub GetUserDefaults {
while (my $thisLine = <$defaults>) {
chomp $thisLine;
if ($thisLine =~ /^Text editor: (.*)$/) {
- $textEditor = "\"$1\"";
+ $textEditor = $1;
+ if ($^O eq "MSWin32" || $^O eq "MSWin64") {$textEditor =~ s/^(.*)$/"$1"/g;}
} elsif ($thisLine =~ /^Repository directory: (.*)$/) {
$repoPath = $1
} elsif ($thisLine =~ /^HTML browser: (.*)$/) {
- $browser = "\"$1\"";
+ $browser = $1;
+ if ($^O eq "MSWin32" || $^O eq "MSWin64") {$textEditor =~ s/^(.*)$/"$1"/g;}
}
}
@@ -133,8 +135,9 @@ sub ParseLine {
while (length $ch < $mxl) {$ch =~ s/^/0/}
while (length $vs < $mxl) {$vs =~ s/^/0/}
$xmlFile = "$repoPath/OSHB/${numBk}.xml";
- say LOG "\n\$wa{$fullBk}/\$ch/\$vs: $wa{$fullBk}/$ch/$vs\nTo system:\n$textEditor $repoPath/en_tn/$wa{$fullBk}/$ch/$vs.md\n";
- if ($^O eq "darwin") {system `$textEditor $repoPath/en_tn/$wa{$fullBk}/$ch/$vs.md`}
+ $tN_page = "$repoPath/en_tn/$wa{$fullBk}/$ch/${vs}.md";
+ say LOG "\n\$wa{$fullBk}/\$ch/\$vs: $wa{$fullBk}/$ch/$vs\nTo system:\n$textEditor $tN_page\n";
+ if ($^O eq "darwin") {system `$textEditor $tN_page`}
#say "open -a /Applications/Logos.app \"logos4:TextComparison;ref=BibleBHS.$lbsBk${sch}.$svs;res=esv,niv2011,niv,nasb95,nrsv,gs-netbible,nlt,leb,kjv1900\"";
if ($^O eq "darwin") {system `open -a /Applications/Logos.app "logos4:TextComparison;ref=BibleNIV.$lbsBk${sch}.$svs;res=esv,niv2011,niv,nasb95,nrsv,gs-netbible,nlt,leb,kjv1900"`}
}
@@ -228,6 +231,7 @@ sub FindVerse {
sub ChecktWPages{
+ say "Checking tW pages";
say LOG "<<$word>>";
if ($word eq "") {
say "\nThere is no \$word for \$strong = $strong in $ref\n$thisULB\n";
@@ -237,14 +241,16 @@ sub ChecktWPages{
say OUT " ";
foreach my $file ( @tWfiles ) {
my $fileText = read_file("$file", binmode => 'utf8');
+ my $foundHere;
# While finds entries and Strong's numbers
while ($fileText =~ /($strong)[^\d]|^(# [^\n]*\b$word\b)/g) {
+ $foundHere = 1;
#system `clear`;
my $abb = $file;
$abb =~ s/.md$//;
say OUT "$abb
\n";
- $outputFiles .= "$file "
}
+ if ($foundHere == 1) {unless (exists $tW_file{$file}) {$tW_file{$file} = $file}}
}
say OUT "
\n";
- $outputFiles .= "$file "
+ unless (exists $tW_file{$file}) {$tW_file{$file} = $file}
}
}
say OUT "