#!/usr/bin/env bash # Recursively dump all blobs in the subtree identified by ID. set -o pipefail usage() { cat <&2 exit 1 ;; esac } if test $# -ne 1 then usage 1>&2 exit 1 fi top="$1" type=$(git cat-file -t "$top") || exit $? cat-item "$top" "$type"