#!/bin/bash tree -J ../theories -P "*.v" | jq --arg "current" "$1" -r ' ("../" * ($current | [ scan("/+") ] | length)) as $prefix | def make_item_link(prefix): (if $current == prefix + .name then " class=\"current\"" else "" end) as $extra | "\(.name | @html)"; def handle_item(prefix): if .type == "directory" then "