3 # List all bookcodes that match given language.
6 # list-bookcodes-by-lang.sh en es
8 if [ ! -d "$AONDIR" ]; then
9 >&2 echo "Please set the AONDIR environment variable"
13 book_db="$AONDIR/common/sqlite/bookcodes.db"
17 if [[ ! $lang =~ ^[a-z][a-z]$ ]]; then
18 >&2 echo "invalid language"
22 sqlite3 -noheader "$book_db" <<EOF