#!/bin/bash shopt -s extglob : "${OFFSET:=0}" codepoint="$((0xF3A00 + OFFSET * 256))" while read -r glyph_json; do ascii_ortho="$(jq -r '.ortho | gsub("θ"; "th") | gsub("∫"; "sh") | @uri | gsub("%"; "q")' <<<"$glyph_json")" printf '%s\t=\t%x\n' "$ascii_ortho" "$codepoint" codepoint="$((codepoint + 1))" done < <(cue export -p shenikan | jq -c '.dictionary.glyphs[]')