Bible Study Kit in Obsidian Scripts (Help and Support)

Though I love the Bible Study Kit in Obsidian from @Joschua, I am wondering why everybody posts his help and support the release info thread.

Maybe this could be an example or a filter to reduce the forgotten questions.

I would love to help if someone has trouble running the script or ruby trouble in this thread and maybe we will even find another place to do this in the upcoming future.

3 Likes

Troubleshooting Ruby Installation Issues

Ruby - is?

Ruby is a great programming language running with an interpreter. The toolchain installation might be not so easy if you are not trained in setting up a development system.

For Windows Users I would recommend the PowerShell Tool scoop - a really great command line package installer, that is even able to manage different ruby versions on the same system.

For Mac users I still have to look for a good and stable solution. Many would suggest homebrew / brew another package manager that I am not really happy with (maybe I did something wrong…all the times I tried it).

For linux you have to look for the correct package manager on you system (like pacman for Arch Linux)

Gettting the installed and active version of ruby is done with the command on the terminal / command line / powershell

 ruby --version 

IMPORTANT!
If you post something here it would be great to include your operating system (including the version like: Window 10 or Mac Os 10.42)
and the version of your ruby installation

Gems ?

Ruby has a package / extension system and a gem is a package.

After installing ruby you are able to add / remove (download and install) those gems to your lokal installation.

Installing a specific package / gem in done by the command:

gem install {{package_name}} -v {{gem-version}}

(The {{ }} are only for highlighting purpose so an example would be:

gem install asciidoctor -v 2.0.17

NOTE:
Installing a gem often installs all the necessary gems that are needed from this gem.

Hi Felix,

Thanks for creating this thread!

I’m running into issues trying to download the NRSV translation via the Bible Study Kit. I’m running the latest version of MacOS.

Every time I run the following in Terminal:

bash bg2obs.sh -v NRSV -beai

I get the following error in response:

bg2obs.sh: line 1: syntax error near unexpected token `newline'
bg2obs.sh: line 1: `<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">'

I’m positive that my files are all in the right place, and that I’m in the correct directory.

Also, I installed Ruby via a guide I found online, and I updated my gems using this command:

sudo gem install colorize optparse clipboard

I’m not sure where to go from here. Thanks for any help you can provide!

1 Like

that sounds really strange. Could you copy the fist three lines of slyour bash script into a message of this thread?

It sound like the script starts with an html tag (’<html DTD…’)

the line 1 should be ‘#!/bin/bash’

I finally figured it out after trying the Script again. I wasn’t downloading the files correctly from GitHub. In case this helps anyone else out there, be sure to click the green “code” button (top-right); then, via the dropdown, select “Download ZIP.” I was copying the code manually into a TextEdit document, but I couldn’t save the file in the correct formal. So, now, everything works and I realize how easy is all of this to do. Thanks for looking into this for me!

Hi @Felix42

I have one for you!
V11.6 MAC OSX
ruby 2.6.3p62 - updated with brew after brew was updated to 3.3.16-17

I downloaded ESV…the first chapter is repeated for every book.
Then…have not looked exhaustively but seems like books with a number like “1 John”
have the following error:
e[0;31;49mError: could not parse data from BibleGateway: please check your usage, and if still a problem, please raise an issue on GitHub.e[0m
and this is all the file contains.

Wonder if I need to update Ruby…

Thanks in advance. This is a great concept from @Joschua with your support…I hope to publish my recipe when done.

Greg

FIXED: Need to use older version of .rb script 1.4.3 from jgclark/Biblegateway…on Github.
Both errors gone.

1 Like

I can’t seem to run the script at all.

I’m in Windows 11. Followed instructions to install Ruby, with all its extra parts and pieces. (Can successfully verify from the command line that it is, in fact, installed.)

Followed instructions to install the three gems indicated by the original kit.

Downloaded and extracted the ZIPs for both scripts to the same folder. (I got the impression from the instructions that this is what I should need to do, although this could possibly be the issue because it seems to have overwritten a couple of duplicate files between the two.)

I’ve made two minor edits to the files: changed the version in config.sh from ESV to NKJV, and changed LORD in bg2md.rb to YHWH, which I think (hope!) shouldn’t do anything but change the output of that one word.

chmod 755 bg2md.rb tells me it “is not recognized as an internal or external command,
operable program or batch file.” Likewise, I can’t run bash bg2md.rb or bash bg2obs.sh or bg2md.rb or bg2obs.sh - they all give me that same error message that it’s not a recognized command, operable program, or batch file.