for i in ??
do
cp -r $i $i.new
rm -rf $i
mv $i.new $i
done
in your .git/objects/ directory (CAREFUL! Any script that does "rm -rf"
should be double- and triple-checked for sanity! ;)
Insanity is copying the data rather than just the file name. Git is
good about not reading unnecessary files, and anything necessary should
be cached, so on-disk fragmentation is not a concern.
rmdir --ignore-fail-on-non-empty ?? # Probably unnecessary.
for i in ??
do
mkdir $i.new
mv $i/* $i.new
rmdir $i
mv $i.new $i
done