Jump to content

RegexForAccordance


Darin Franklin

Recommended Posts

Hi Fabian.  I will summarize here what we discussed in private messages.

 

The regular expression you want is: ^\W*and\b

If you use only this: ^and

then it fails to find Mark 8:20 because of the leading quotation mark, and it matches Mark 3:18, which starts with "Andrew".

 

Mark 8:20 “And the seven for the four thousand, how many baskets full of broken pieces did you take up?” And they said to him, “Seven.”

Mark 3:18 Andrew, and Philip, and Bartholomew, and Matthew, and Thomas, and James the son of Alphaeus, and Thaddaeus, and Simon the Zealot,

 

^ matches the beginning of the line

\W* matches zero or more non-word characters, like punctuation and space.

\b matches a word boundary.

 

This results in 394 verses for Mark, and the list matches what Accordance finds with this query:

and <WITHIN 1 Words> [FIELD BEGIN] <AND> [RANGE Mark]

 

I can't reproduce your result of 329 verses.  Let me know if you ever see it again.

 

  • Like 1
Link to comment
Share on other sites

Hello Darin

Thank for your explanations.

 

Greetings

 

Fabian 

Link to comment
Share on other sites

  • 3 years later...

Hello Darin

 

Many thanks for the 1.0.9 update. 

 

May you wan't to check the Dark Mode feature? The text on the left side is nearly unreadable.

post-32723-0-02554000-1594826537_thumb.png

 

Thanks

 

Fabian

Edited by Fabian
  • Like 1
Link to comment
Share on other sites

Thank you very much. Version 1.0.10 fixes Dark Mode.

v1.0.10-dark.png

 
I also updated the documentation page with some more detailed examples.

Version 1.0.9 fixed the problem with Accordance 13.1 that I mentioned in another post.
https://www.accordancebible.com/forums/topic/29182-applescript-behavior-change-for-fetching-verses/

Edited by Darin Franklin
  • Like 2
Link to comment
Share on other sites

Hello Darin 

 

Many thanks.

 

Is there a search "How many words per verse".

E.g in

 

Verse     Hits

Gen 1:1  7

Gen 1:2  8

Gen 1:3  5

 

Thanks

 

Fabian

Link to comment
Share on other sites

Is there a search "How many words per verse".

 

No, it does not show the number of hits for each verse. 

  • Like 1
Link to comment
Share on other sites

No, it does not show the number of hits for each verse. 

Thanks.

Link to comment
Share on other sites

  • 4 months later...

Hello Darin

 

The Quran verse scheme is a little bit different in Accordance. First it comes the Q and then the chapter/book number, like Q2. After them there is a space and then comes the verse number. Like Q2 13. Accordance handle here the Books and the Chapter equal. So if you press the arrow for next chapter or next book it goes from Q2 to Q3. 

 

If I'm now on the European notation, your Quran export looks like   Q2 20,25,72,87,100,167,178,191,217,229-231,233,266,286; Q3 4,21,37,81,165

 

The Problem now is. In the European notation to add verses on the same Chapter there are a dot not a comma. The Comma is to distinguish between the chapter and the verses. Like Luke 18,3 and Luke 18,3.5. I know some older notation use also the dot to distinguish between the chapter and the verses.

 

If I now press the ref button I got an error in Accordance. Der Eintrag “Q2 20,25,72,87,100,167,178,191,217,229-231,233,266,286; Q3 4,21,37,81,165; Q4 56,91,93,157; Q5 36,64,70,103; Q6 31,99,110,138,141-142; Q7 8-9,31,157,189; Q8 29,41,56; Q9 29,80,83,124,126-127; Q10 41; Q11 38,40; Q12 65,72; Q13 12; Q14 50; Q15 2; Q16 7,14,81; Q17 4,7,31,33,51,69,97; Q18 32,48; Q20 37,39,55,100-101,111; Q22 2,5,22,58; Q23 27,44,62; Q24 6,8,54,58; Q25 1,14; Q26 119,157; Q27 44,49; Q28 54,76; Q32 20; Q33 31,58,72; Q35 11-12,18; Q36 41,79; Q37 146; Q38 15; Q39 68; Q40 11; Q41 1,21,47; Q47 4; Q50 9-10; Q53 13,38; Q54 13,20; Q55 11,54; Q59 2,5; Q60 12; Q62 5,10; Q67 3-4,8; Q68 46; Q69 7; Q71 7; Q76 21; Q79 6-7; Q80 29,31; Q82 8; Q84 17; Q104 6; Q111 1” kann nicht gefunden werden.

 

If the verse refs are Q2 20.25.72.87 it works. So to export from RegexforAccordance to add more verses it needs the . not the , 

 

To Test you can use the Hebrew Quran on http://www.accordancefiles1.com/exchange/tools.htm

 

Thanks

 

Fabian

Link to comment
Share on other sites

If I'm now on the European notation, your Quran export looks like   Q2 20,25,72,87,100,167,178,191,217,229-231,233,266,286; Q3 4,21,37,81,165

 

If the verse refs are Q2 20.25.72.87 it works. So to export from RegexforAccordance to add more verses it needs the . not the , 

 

Thanks, Fabian.  I fixed this in version 1.0.11 by adding a user preference: Preferences > Advanced > Use European verse notation.  The problem happens in any single-chapter book, like Obadiah.

  • Like 2
Link to comment
Share on other sites

Thanks, Fabian.  I fixed this in version 1.0.11 by adding a user preference: Preferences > Advanced > Use European verse notation.  The problem happens in any single-chapter book, like Obadiah.

Thanks for the amazing work you have done!

Link to comment
Share on other sites

Hello Darin 

 

Many thanks. 

 

A question is there a reason the results are now in sektions? Is this due to the change of 13.1?

 

post-32723-0-55967300-1607793132_thumb.png

 

Thanks again.

 

 

Fabian

Link to comment
Share on other sites

A question is there a reason the results are now in sektions? Is this due to the change of 13.1?

 

It limits the length of the accord URL, or else Accordance will crash. It has always done that.

  • Like 1
Link to comment
Share on other sites

Ah thanks. 

 

May you consider a Universal App for the Apple M1? Or do you have to wait until GitHub is ready for it? If I'm not wrong then I see no GitHub App in my arsenal which is M1 ready. 

 

Fabian

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...