jasford/python-bible — pull request #3 by Ganon11 (2014-05-08 14:49:31+00:00)
Title: A few tweaks

First, I added "abbreviations" for book names like "II John" instead of "2 John". This was simply to ease the interaction between this module and https://github.com/davisd/python-scriptures

Second, I noticed that for books with only one chapter (e.g. 2 John or Philemon) the Verse constructor could not understand a reference like "2 John 3". I added simple_ref_re to find verse references when the book was known to be single-chapter, and automatically set self.book to 1.

This may run into trouble with strings like "2 John 3" since it would find the 2 first. For my case, the string was always "II John 3", so it worked. Maybe the regex should be r'\d{1,3}$' ?