This commit is contained in:
Paul Irish 2022-08-16 10:00:04 -07:00
parent 6136187009
commit 1f6b93c2d0

View file

@ -33,10 +33,10 @@ while getopts "n:" opt; do
done done
shift $((OPTIND-1)) shift $((OPTIND-1))
# Dont collect upstream details ([ahead 2, behind 54]) for big-ass git repos. It's slow. # Dont collect upstream details ("[ahead 2, behind 54]"") for big-ass git repos. It's slow.
# git count-objects -v | grep -- "in-pack" | cut -d " " -f 2 # TODO: count-object -v is slow. Maybe store setting in repo config somehow
# TODO, use `git count-objects -v` and consider `in-pack` and `size-pack` instead of special casing chromium obj_count=$(git count-objects -v 2>/dev/null | grep -- "in-pack" | cut -d " " -f 2)
if git config --get remote.origin.url | grep -q chromium.googlesource.com; then if [ "$obj_count" -gt "5000000" ]; then
upstream_deets="" upstream_deets=""
else else
upstream_deets="%(color:yellow)%(upstream:track)%(color:reset)" upstream_deets="%(color:yellow)%(upstream:track)%(color:reset)"