Skip to content

erykjj/refractor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

63 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

refractor

Commandline/terminal reference extractor utility that finds scriptures and publication references1. Works with both text files and .docx (MS Word) documents. Multiple languages are supported.

You can set your default language code and Bible book format in a refractor.conf file alongside the binary.

Publication references are only parsed within () and [].

Scripture references only include the ones with verses (not whole chapters or books), and they will be "cleaned up" (rewritten in selected format):

II Chronicles 2:3 --> 2Ch 2:3
1-Cor 1:11 --> 1Co 1:11
1st Peter 1:1 --> 1Pe 1:1
1.John 5:3 --> 1Jo 5:3

You will get a list that you can paste into the search box on Watchtower ONLINE LIBRARY2, or a link to see your results directly. A refractor_output.html file is generated in the directory where the binary is located.

Downloads

Usage

  refractor [-h | -v | -l] | [-r] [-s] [--sorted] [--full | --standard | --official] -c:code <infile>
  refractor.exe [-h | -v | -l] | [-r] [-s] [--sorted] [--full | --standard | --official] -c:code <infile>

Options:
  -h, --help                      Show this help message and exit
  -v, --version                   Show the version and exit

  -c:<code>, --code=<code>        Language code or symbol (en by default)
  -l, --list                      List supported languages

  -r, --references                Output publication references
  -s, --scriptures                Output scriptures (if neither -r nor -s
                                    is provided, both shown)

Scripture (book names) rewrite options:
  --full                          Use full name
  --standard                      Use standard name
  --official                      Use official name (default)

<infile>                          File to process (docx or text)

Examples

Linux/macOS: ./refractor -c:S bosquejo.docx

Windows: refractor.exe -c:en talk_outline.txt


Static Badge

Feel free to get in touch and post any issues and/or suggestions.


Footnotes:

Footnotes

  1. For publications of Jehovah's Witnesses

  2. Copyright Watch Tower Bible and Tract Society of Pennsylvania

About

REFERENCE EXTRACTOR - scripture and publication reference parser

Topics

Resources

License

Stars

Watchers

Forks

Contributors

Languages