Created
September 10, 2021 00:51
-
-
Save lucasburlingham/798425e5d727ff30166b472739d926d2 to your computer and use it in GitHub Desktop.
Search Biblegateway from the command-line, opening results in the default browser
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# (C) Lucas Burlingham 2021 | |
# MIT License | |
# Command-line client to Biblegateway | |
# | |
# Defaults to NASB if version is not specified | |
if [ -z "$1" ]; then | |
echo "Usage: " | |
echo " bible [Book] [Chapter:Verse-Verse] [Version]" | |
elif [ -z "$3" ]; then | |
# default to NASB | |
xdg-open "https://www.biblegateway.com/passage?search=$1+$2&version=NASB" & | |
exit | |
else | |
xdg-open "https://www.biblegateway.com/passage?search=$1+$2&version=$3" & | |
exit | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment